Is There A Way To Setup Webpack Config To Load Specific Core-js Entries
DISCLAIMER: I'm not terribly familiar with webpack or babel outside of simple setup, so if the question isn't clear then I apologize and will do my best to offer further clarity. S
Solution 1:
You can add this by webpack. Take a look at the documentation https://github.com/zloirock/core-js#babelpreset-env You need babel .babelrc
{
"presets": [
[
"@babel/preset-env",
{
"useBuiltIns": "usage",
"corejs": 3
}
]
]
}
Then you do not need to add dependency in main.js all dependencies are added automatically by core-js
I prepared the code https://github.com/tomik23/webpack-babel-corejs
Post a Comment for "Is There A Way To Setup Webpack Config To Load Specific Core-js Entries"