import 'babel-polyfill'
看 vue-cli 生成的项目 Babel 配置,main.js
中已经没有import 'babel-polyfill'
了,是因为
使用了babel-preset-env
吗?
{
"presets": [
["env", {
"modules": false
}],
"stage-2"
],
"plugins": ["transform-runtime"],
"env": {
"test": {
"presets": ["env", "stage-2"],
"plugins": ["transform-es2015-modules-commonjs", "dynamic-import-node"]
}
}
}