Package Exports
- @bevry/nodejs-ecmascript-compatibility
Readme
Node.js ECMAScript Compatibility
API for the Node.js ECMAScript Compatibility information, such that for a particular Node.js release, you get details on which and how many features of an ECMAScript version are supported.
Usage
import {
fetchNodeVersionCompatibility,
fetchNodeVersionsCompatibility,
fetchMutualCompatibleESVersionsForNodeVersions,
fetchExclusiveCompatibleESVersionsForNodeVersions,
fetchAllCompatibleESVersionsForNodeVersions,
} from '@bevry/nodejs-ecmascript-compatibility'
// fetch the compatibility information for the current node.js version
fetchNodeVersionCompatibility().then(console.log)
// fetch the details for a specific node.js version
fetchNodeVersionCompatibility('4.9.1').then(console.log)
// fetch the details for multiple node.js versions
fetchNodeVersionsCompatibility(['4.9.1', '12.0.0']).then(console.log)
// fetch each ECMAScript version that supports both releases
fetchMutualCompatibleESVersionsForNodeVersions(['4.9.1', '12.0.0']).then(
console.log
)
// fetch the minimum ECMAScript versions required to support both releases
fetchExclusiveCompatibleESVersionsForNodeVersions(['4.9.1', '12.0.0']).then(
console.log
)
// fetch each ECMAScript version that supports either release
fetchAllCompatibleESVersionsForNodeVersions(['4.9.1', '12.0.0']).then(
console.log
)
Install
- Install:
npm install --save @bevry/nodejs-ecmascript-compatibility
- Import:
import * as pkg from ('@bevry/nodejs-ecmascript-compatibility')
- Require:
const pkg = require('@bevry/nodejs-ecmascript-compatibility')
<script type="module">
import * as pkg from '//cdn.skypack.dev/@bevry/nodejs-ecmascript-compatibility@^4.0.0'
</script>
<script type="module">
import * as pkg from '//unpkg.com/@bevry/nodejs-ecmascript-compatibility@^4.0.0'
</script>
<script type="module">
import * as pkg from '//dev.jspm.io/@bevry/nodejs-ecmascript-compatibility@4.0.0'
</script>
Editions
This package is published with the following editions:
@bevry/nodejs-ecmascript-compatibility/source/index.ts
is TypeScript source code with Import for modules@bevry/nodejs-ecmascript-compatibility/edition-browsers/index.js
is TypeScript compiled against ES2020 for web browsers with Import for modules@bevry/nodejs-ecmascript-compatibility
aliases@bevry/nodejs-ecmascript-compatibility/edition-es2020/index.js
@bevry/nodejs-ecmascript-compatibility/edition-es2020/index.js
is TypeScript compiled against ES2020 for Node.js 10 || 12 || 14 with Require for modules@bevry/nodejs-ecmascript-compatibility/edition-es2020-esm/index.js
is TypeScript compiled against ES2020 for Node.js 12 || 14 with Import for modules
History
Discover the release history by heading on over to the HISTORY.md
file.
Contribute
Discover how you can contribute by heading on over to the CONTRIBUTING.md
file.
Backers
Maintainers
These amazing people are maintaining this project:
Sponsors
No sponsors yet! Will you be the first?
Contributors
These amazing people have contributed code to this project:
Discover how you can contribute by heading on over to the CONTRIBUTING.md
file.
License
Unless stated otherwise all works are:
- Copyright © 2021+ Benjamin Lupton
and licensed under: