Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add compat data for Hermes #1099

Merged
merged 4 commits into from Jul 24, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
@@ -1,6 +1,7 @@
## Changelog
##### Unreleased
- Polyfill `Promise` with `unhandledrejection` event support (browser style) in Deno < [1.24](https://github.com/denoland/deno/releases/tag/v1.24.0)
- Added compat data for Hermes, [#1099](https://github.com/zloirock/core-js/issues/1099)
- Added compat data for Oculus Browser, [#1098](https://github.com/zloirock/core-js/issues/1098)

##### [3.23.5 - 2022.07.18](https://github.com/zloirock/core-js/releases/tag/v3.23.5)
Expand Down
2 changes: 2 additions & 0 deletions CONTRIBUTING.md
Expand Up @@ -26,6 +26,7 @@ For updating `core-js-compat` data:
- If you want to add new data for NodeJS, run `npm run compat-node` with the installed required NodeJS version and you will see the results in the console. Use `npm run compat-node-json` if you want to get the result as JSON.
- If you want to add new data for Deno, run `npm run compat-deno` with the installed required Deno version and you will see the results in the console. Use `npm run compat-deno-json` if you want to get the result as JSON.
- If you want to add new data for Rhino, set the required Rhino version in `compat-rhino-prepare` NPM script in [`package.json`](./package.json), run `npm run compat-rhino` and you will see the results in the console.
- If you want to add new data for Hermes, run `npm run compat-hermes -- YOR_PATH_TO_HERMES` and you will see the results in the console.
- After getting this data, add it to [`packages/core-js-compat/src/data.mjs`](./packages/core-js-compat/src/data.mjs).
- If you want to add new mapping (for example, to add a new iOS Safari version based on Safari or NodeJS based on Chrome), add it to [`packages/core-js-compat/src/mapping.mjs`](./packages/core-js-compat/src/mapping.mjs).

Expand All @@ -37,6 +38,7 @@ engine | mandatory check | how to run tests | base data inherits from
`edge` | features | browser runner | `ie` (<=18), `chrome` (>=74) |
`electron` | | browser runner | `chrome` | required
`firefox` | features | browser runner | |
`hermes` | features | hermes runner | |
`ie` | features | browser runner | |
`ios` | | browser runner | `safari` | required
`node` | non-ES features | node runner | `chrome` (only ES) | required
Expand Down
1 change: 1 addition & 0 deletions package.json
Expand Up @@ -107,6 +107,7 @@
"compat-node-json": "node tests/compat/node-runner --mode=JSON",
"compat-deno": "deno run --allow-read tests/compat/deno-runner.mjs",
"compat-deno-json": "deno run --allow-read tests/compat/deno-runner.mjs --mode=JSON",
"compat-hermes": "zx tests/compat/hermes-adapter.mjs",
"compat-rhino": "run-s compat-rhino-prepare compat-rhino-run",
"compat-rhino-prepare": "zx tests/compat/rhino-prepare.mjs --version=1.7.14",
"compat-rhino-run": "java -jar tests/compat/rhino.jar -version 200 -require tests/compat/rhino-runner.js",
Expand Down
1 change: 1 addition & 0 deletions packages/core-js-compat/README.md
Expand Up @@ -71,6 +71,7 @@ console.log(targets);
edge: '13', // Edge version
electron: '5.0', // Electron framework version
firefox: '15', // Firefox version
hermes: '0.11', // Hermes version
ie: '8', // Internet Explorer version
ios: '13.0', // iOS Safari version
node: 'current', // NodeJS version, you can use 'current' for set it to currently used
Expand Down