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 build warning #549

Closed
mmarton opened this issue Mar 27, 2019 · 3 comments
Closed

Babel build warning #549

mmarton opened this issue Mar 27, 2019 · 3 comments

Comments

@mmarton
Copy link

mmarton commented Mar 27, 2019

Hi!

I'v got the following warning during build. I'm not sure it's encore related or i just missed some config.
@symfony/webpack-encore@0.25.0
@babel/preset-env@7.4.2

Running webpack ...


WARNING: We noticed you're using the `useBuiltIns` option without declaring a core-js version. Currently, we assume version 2.x when no version is passed. Since this default version will likely change in future versions of Babel, we recommend explicitly setting the core-js version you are using via the `corejs` option.

You should also be sure that the version you pass to the `corejs` option matches the version specified in your `package.json`'s `dependencies` section. If it doesn't, you need to run one of the following commands:

  npm install --save core-js@2    npm install --save core-js@3
  yarn add core-js@2              yarn add core-js@3

Could you help me?
Thanks

@Kocal
Copy link
Contributor

Kocal commented Mar 27, 2019

See #545 :)

@mmarton
Copy link
Author

mmarton commented Mar 27, 2019

I've missed that, thanks

@mmarton mmarton closed this as completed Mar 27, 2019
@Lyrkan
Copy link
Collaborator

Lyrkan commented Mar 27, 2019

Note that if you don't use polyfills (ie. if you don't import core-js or @babel/polyfill anywhere with the default Babel' settings), you can remove this warning by calling:

Encore.configureBabel(() => {}, {
  useBuiltIns: false
});

If you do use them, you should be fine as long as you explictely have core-js@2 in your dependencies.

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

3 participants