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

[Babel 8] Set babelrc: false by default #15975

Open
nicolo-ribaudo opened this issue Sep 15, 2023 · 0 comments
Open

[Babel 8] Set babelrc: false by default #15975

nicolo-ribaudo opened this issue Sep 15, 2023 · 0 comments
Milestone

Comments

@nicolo-ribaudo
Copy link
Member

nicolo-ribaudo commented Sep 15, 2023

We have two types of configuration files: babel.config.js and .babelrc.js (docs).

.babelrc files are very expensive to load, because we must check if they are present in the file's folder or in any parent folder. They are also rarely used, because for 99% of use cases babel.config.js is enough. To save on I/O cost, we should only load them if the babelrc option is explicitly set to true.

However, this change has a disadvantage: some people like to keep their config in package.json, and we threat it as if it was a .babelrc file. Maybe we should add a rootConfig: true option in package.json#babel, to make it behave like a babel.config.json?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants