Programming language New ECMAScript standard released
Programming language New ECMAScript standard released |
Ultimately, the release of Ecmascript 2020 now only has a formal character. The innovations of the new language standard, which have been approved by ECMA International and the committee responsible for this in the Standardization Authority (Technical Committee 39; TC39), have long been known. The feature set has been fixed since April 2020, and in the meantime it was only necessary to check it. The Ecmascript standards have been published annually since 2015, always in June.Ecmascript 2020 is the eleventh edition of the language standard.
Seven everyday features
Seven features are central, which have now been officially released as part of Ecmascript 2020. There is also an extension to the specification for the for-in loop. The new functions meet areas such as shortening spellings, a new data type and the possibility to increase the performance of websites.
Among the new features, the new Nullish
Coalescing Operator and the Optional Chaining complement each other perfectly. The former provides a more reliable way to save an alternative in case of an undefined value. The Optional Chaining Operator, on the other hand, introduces a shortened notation that allows a simpler check for undefined values. The combination of Nullish Coalescing Operator and Optional Chaining is designed to keep long code fragments simple and readable.
The Promise.allSettled extension is designed to enrich work in an asynchronous context with a complete list of all requests - regardless of whether they were successful or not. Due to the complete output of all processed requests, all problems can be detected in the event of an error, and it is still possible to continue working with successful partial requests. With the introduction of dynamic imports, there are also new options for improving the performance of a website by reloading certain modules only when required.
Regular expressions and Bigint
As in recent years, work has been done on handling regular expressions. The new match All feature makes it possible to output metadata such as the index and the specified capturing groups with the search hit.
With the new, primitive data type Bigint a larger number space is made available. It makes it possible to represent integers above 253, which had previously represented the upper limit with the existing number type. Finally, the introduction of global This allows all platforms to use a unified, global object in Javascript.
Many of the new functions are already supported by common browsers and can be implemented using the JavaScript parser Babel. The most detailed information about ECMAScript 2020 is available on the standard page.