diff --git a/lib/build/tasks/webpack/webpack.config.js b/lib/build/tasks/webpack/webpack.config.js index be956f37f1..01a0015f55 100644 --- a/lib/build/tasks/webpack/webpack.config.js +++ b/lib/build/tasks/webpack/webpack.config.js @@ -50,10 +50,8 @@ module.exports = { path.resolve(path.resolve('.'), 'node_modules/internal-carto.js') ], options: { - presets: [ - ['es2015', { 'modules': false }] - ], - plugins: ['transform-object-assign', 'transform-object-rest-spread'] + presets: ['@babel/env'], + plugins: ['@babel/plugin-transform-object-assign', '@babel/plugin-proposal-object-rest-spread'] } }, { diff --git a/webpack/carto-node/webpack.config.js b/webpack/carto-node/webpack.config.js index 02f40c1a8b..7371098640 100644 --- a/webpack/carto-node/webpack.config.js +++ b/webpack/carto-node/webpack.config.js @@ -34,7 +34,8 @@ const config = { path.resolve(__dirname, '../../lib/assets/javascripts/carto-node') ], options: { - babelrc: true + presets: ['@babel/env'], + plugins: ['@babel/plugin-transform-object-assign'] } }] },