Tell Babel to target Electron 3.0.2; enable chunk splitting

This commit is contained in:
Christopher Willis-Ford 2018-10-13 01:09:45 -07:00
parent 751406722d
commit 1de7228a8c

View file

@ -29,13 +29,18 @@ module.exports = {
}] }]
], ],
presets: [ presets: [
['@babel/env', {targets: {electron: '2.0.7'}}], ['@babel/env', {targets: {electron: '3.0.2'}}],
'@babel/react' '@babel/react'
] ]
} }
} }
] ]
}, },
optimization: {
splitChunks: {
chunks: 'all'
}
},
plugins: [ plugins: [
new CopyWebpackPlugin([{ new CopyWebpackPlugin([{
from: path.resolve(__dirname, 'node_modules', 'scratch-gui', 'dist', 'static'), from: path.resolve(__dirname, 'node_modules', 'scratch-gui', 'dist', 'static'),