-
-
Notifications
You must be signed in to change notification settings - Fork 5.6k
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
Move all runtime helpers to individual files #16495
Conversation
packages/babel-runtime/package.json
Outdated
@@ -26,6 +26,15 @@ | |||
"./helpers/AsyncGenerator.js" | |||
], | |||
"./helpers/esm/AsyncGenerator": "./helpers/esm/AsyncGenerator.js", | |||
"./helpers/AwaitValue": [ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These package.json files are now just sorted alphabetically, but the contents are the same.
Build successful! You can test your changes in the REPL here: https://babeljs.io/repl/build/56904 |
cf1de47
to
624ef72
Compare
624ef72
to
b98b0dc
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe it would be better to keep Object.freeze(helpers)
?
In tests we mutate the |
I'll open a good first issue to convert the helpers to TS (in chunks) |
Fixes #1, Fixes #2
After this PR, since there is a build step for all helpers, I plan to move
babel/packages/babel-helpers/src/index.ts
Line 42 in 6e3539b
This PR caught a problem with our Babel7/8 integration tests: some tests fail because the helpers are missing (for example, old decorator helpers), but we didn't notice because we where generating those helpers even in Babel 8 mode during the test.