corejs2 per @babel/plugin-transform-runtime@7.0.0-rc.1

This commit is contained in:
Michael Bradley, Jr 2018-08-12 21:40:22 -05:00 committed by Iuri Matias
parent 1852809cb0
commit eb874f32ac
1 changed files with 15 additions and 2 deletions

View File

@ -133,8 +133,21 @@ class WebpackProcess extends ProcessWrapper {
}),
plugins: [
"babel-plugin-webpack-aliases",
"@babel/plugin-transform-runtime"
].map(require.resolve),
[
"@babel/plugin-transform-runtime", {
corejs: 2,
useESModules: true
}
]
].map(pkg => {
if (Array.isArray(pkg)) {
let _pkg = pkg[0];
pkg[0] = require.resolve(_pkg);
return pkg;
} else {
return require.resolve(pkg);
}
}),
compact: false
}
}