Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Mapping of Node.js version to ECMAScript version [closed]

Is there a mapping somewhere from Node.js version, e.g. 0.10, or 14, to the corresponding ECMAScript version, e.g. ES5, ES2020?

As this question is closed, I can't post the solution I came up with as an answer, so it is here instead.

@bevry/node-versions includes fetchESVersionForNodeVersion(nodeVersion: string): Promise<string> which will fetch the ECMAScript version that was ratified by the time that the Node.js version was released.

like image 880
balupton Avatar asked Oct 26 '20 22:10

balupton


1 Answers

Which features ship with which Node.js version by default?

The website node.green provides an excellent overview over supported ECMAScript features in various versions of Node.js, based on kangax's compat-table.

Source: https://nodejs.org/en/docs/es6/

like image 185
iwaduarte Avatar answered Sep 18 '22 08:09

iwaduarte