JavaScript was created in May 1995 in 10 days, by Brendan Eich. Eich worked at Netscape and implemented JavaScript for their web browser, Netscape Navigator.
The idea was that major interactive parts of the client-side web were to be implemented in Java. JavaScript was supposed to be a glue language for those parts and to also make HTML slightly more interactive. Given its role of assisting Java, JavaScript had to look like Java. That ruled out existing solutions such as Perl, Python, TCL, and others.
Initially, JavaScript’s name changed several times:
There are two standards for JavaScript:
The language described by these standards is called ECMAScript, not JavaScript. A different name was chosen because Sun (now Oracle) had a trademark for the latter name. The “ECMA” in “ECMAScript” comes from the organization that hosts the primary standard.
The original name of that organization was ECMA, an acronym for European Computer Manufacturers Association. It was later changed to Ecma International (with “Ecma” being a proper name, not an acronym) because the organization’s activities had expanded beyond Europe. The initial all-caps acronym explains the spelling of ECMAScript.
Often, JavaScript and ECMAScript mean the same thing. Sometimes the following distinction is made:
Therefore, ECMAScript 6 is a version of the language (its 6th edition).
This is a brief timeline of ECMAScript versions:
TC39 is the committee that evolves JavaScript. Its members are, strictly speaking, companies: Adobe, Apple, Facebook, Google, Microsoft, Mozilla, Opera, Twitter, and others. That is, companies that are usually competitors are working together on JavaScript.
Every two months, TC39 has meetings that member-appointed delegates and invited experts attend. The minutes of those meetings are public in a GitHub repository.
Outside of meetings, TC39 also collaborates with various members and groups of the JavaScript community.
With ECMAScript 6, two issues with the release process used at that time became obvious:
If too much time passes between releases then features that are ready early, have to wait a long time until they can be released. And features that are ready late, risk being rushed to make the deadline.
Features were often designed long before they were implemented and used. Design deficiencies related to implementation and use were therefore discovered too late.
In response to these issues, TC39 instituted the new TC39 process:
The result: smaller, incremental releases, whose features have already been field-tested.
ES2016 was the first ECMAScript version that was designed according to the TC39 process.
Up to and including ES6, it was most common to think about JavaScript in terms of ECMAScript versions – for example, “Does this browser support ES6 yet?”
Starting with ES2016, it’s better to think in individual features: once a feature reaches stage 4, we can safely use it (if it’s supported by the JavaScript engines we are targeting). We don’t have to wait until the next ECMAScript release.
ECMAScript features are designed via proposals that go through the so-called TC39 process. That process comprises six stages:
Stage 0 means a proposal has yet to enter the actual process. This is where most proposals start.
Then the proposal goes through the five maturity stages 1, 2, 2.7, 3 and 4. If it reaches stage 4, it is complete and ready for inclusion in the ECMAScript standard.
The following artifacts are associated with an ECMAScript proposal:
Proposal document: Describes the proposal to JavaScript programmers, with English prose and code examples. Usually the readme of a GitHub repository.
Specification: Written in Ecmarkup, an HTML and Markdown dialect that is supported by a toolchain. That toolchain checks Ecmarkup and renders it to HTML with features tailored to reading specifications (cross-references, highlighting of variable occurrences, etc.).
Tests: Written in JavaScript that check if an implementation conforms to the specification.
Implementations: The functionality of the proposal, implemented in engines and transpilers (such as Babel and TypeScript).
Each stage has entrance criteria regarding the state of the artifacts:
Stage | Proposal | Specification | Tests | Implementations |
---|---|---|---|---|
0 | ||||
1 | draft | |||
2 | finished | draft | ||
2.7 | finished | |||
3 | finished | prototypes | ||
4 | 2 implementations |
Stage 0: ideation and exploration
Stage 1: designing a solution
Stage 2: refining the solution
Stage 2.7: testing and validation
Stage 3: gaining implementation experience
Stage 4: integration into draft specification and eventual inclusion in standard
Figure 5.1 illustrates the TC39 process.
Sources of this section:
how-we-work
, especially the document that explains the work of a proposal champion.
One idea that occasionally comes up is to clean up JavaScript by removing old features and quirks. While the appeal of that idea is obvious, it has significant downsides.
Let’s assume we create a new version of JavaScript that is not backward compatible and fixes all of its flaws. As a result, we’d encounter the following problems:
So what is the solution? This is how JavaScript is evolved:
New versions are always completely backward compatible (but there may occasionally be minor, hardly noticeable clean-ups).
Old features aren’t removed or fixed. Instead, better versions of them are introduced. One example is declaring variables via let
– which is an improved version of var
.
If aspects of the language are changed, it is done inside new syntactic constructs. That is, we opt in implicitly – for example:
yield
is only a keyword inside generators (which were introduced in ES6).
There are several places where you can look up what’s new in each ECMAScript version:
In this book, there is a chapter that lists what’s new in each ECMAScript version. It also links to explanations.
The TC39 repository has a table with finished proposals that states in which ECMAScript versions they were (or will be) introduced.
Section “Introduction” of the ECMAScript language specification lists the new features of each ECMAScript version.
The ECMA-262 repository has a page with releases.
If you are wondering what stages various proposed features are in, consult the GitHub repository proposals
.
Stage 2.7 was added in late 2023, after stages 0, 1, 2, 3, 4 had already been in use for years.
Source: TC39 discussion on 2023-11-30