2024
1 featuresThe transfer() and transferToFixedLength() methods of ArrayBuffer move a buffer from one context to another (for example, to a worker).
2022
1 featuresThe Object.hasOwn() static method checks whether an object has a given property. It's a more robust alternative to the Object.prototype.hasOwnProperty() method.
2021
4 featuresThe BigInt64Array and BigUint64Array typed arrays represent 64-bit integers, signed and unsigned respectively.
The cause property of errors records the specific original cause of the error, particularly for errors that have been re-thrown.
The WeakRef and FinalizationRegistry objects hold references to garbage-collectable objects without creating strong references that prevent their garbage collection.
2020
11 featuresThe BigInt JavaScript type represents integers of any size, including integers too large for the primitive Number type.
The logical AND assignment (&&=) and the logical OR assignment (||=) operators short-circuit the respective binary logical operators.
The nullish coalescing (??) and nullish coalescing assignment (??=) operators return (or assign) its right-hand side operand when its left-hand side operand is null or undefined, and otherwise returns its left-hand side operand.
To improve readability for numeric literals, underscores (_) can be used as separators. For example, 1_050.95 is equivalent to 1050.95.
The #! comment at the absolute start of a script or module is treated as a normal comment and is ignored by the JavaScript engine.
Async generator functions (async function*) create iterators that return multiple promises, one after another, on-demand.
The destructuring assignment syntax is a JavaScript expression that unpacks values from arrays, or properties from objects, into distinct variables.
Omit the binding parameter of a catch clause when you don't need information about the exception in a try ... catch statement.
The spread (...) syntax allows an iterable, such as an array or string, to be expanded in places where zero or more arguments (for function calls) or elements (for array literals) are expected.
Template literals are literals delimited with backtick (`) characters, allowing for multi-line strings, string interpolation with embedded expressions, and special constructs called tagged templates.
The globalThis property accesses the global this value (and hence the global object itself) across environments.
2017
2 featuresThe async and await keywords allow you to use the asynchronous, promise-based behavior of a function without using promise chains.
The exponentiation (**) operator returns the result of raising the first operand to the power of the second operand.
2016
4 featuresGenerator functions (function*) create iterators that return multiple values, one after another, on-demand.
The let and const declarations define block-scoped variables.
The Proxy and Reflect JavaScript built-ins intercept and define custom behavior for fundamental language operations (such as property lookup, assignment, enumeration, or function invocation).
Classes are an object-oriented syntax for JavaScript prototypes.
2015
4 featuresUnicode point escapes (\\u{}) represent Unicode characters within strings.
Functions are series of statements that can be called and return a value. The function keyword (as in function () { }) and arrow (=>) expression create functions. The JavaScript functions protocol includes default and rest parameters and binding to this.
JavaScript is a programming language that runs in browsers, usually through the <script> element. JavaScript has changed over many years. This feature represents the oldest language features, such as built-in objects, statements, and operators. Also known as ECMAScript.
Objects in JavaScript are collections of key-value pairs.