-
-
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
Make the babel instance configurable in babel-register #7263
Comments
Hey @Janpot! We really appreciate you taking the time to report an issue. The collaborators If you need any help, or just have general Babel or JavaScript questions, we have a vibrant Slack |
This would require some refactoring, as Our team tries to be focused at the moment on releasing v7, so I don't expect anyone starting to work on this right now. Community contribution would be invaluable to get this implemented sooner. |
@Andarist I might not think of all intricacies involved, but to me it seems like it's sufficient to plumb a babel through the options and select it here instead of using the imported babel: import babelCore from '@babel/core';
// ...
// inside compile()
const babel = opts.babel || babelCore Wouldn't that be backwards compatible? I can make a PR for that if the babel team agrees. |
Oh yeah, it might very well be that easy. Was looking quickly at the source code and thought that
Me neither 😅 You can start a PR to get ball rolling faster. |
The version of babel that is bundled with
babel-register
might not always be the same one as the one I want to registerlike in this thread: a dependency (a babel plugin) wants to load modules of the dependant with the babel version of the dependant.
I propose to make it configurable like for instance
I wouldn't mind making a PR for something like this if you agree.
The text was updated successfully, but these errors were encountered: