mirror of
https://github.com/scratchfoundation/scratch-storage.git
synced 2025-08-10 21:41:16 -04:00
chore(build): update to webpack 4
This commit is contained in:
parent
fe93eaedae
commit
a0ab19326b
2 changed files with 16 additions and 11 deletions
|
@ -1,7 +1,8 @@
|
|||
const path = require('path');
|
||||
const webpack = require('webpack');
|
||||
const UglifyJsPlugin = require('uglifyjs-webpack-plugin');
|
||||
|
||||
const base = {
|
||||
mode: process.env.NODE_ENV === 'production' ? 'production' : 'development',
|
||||
devtool: 'cheap-module-source-map',
|
||||
module: {
|
||||
rules: [
|
||||
|
@ -17,13 +18,15 @@ const base = {
|
|||
}
|
||||
]
|
||||
},
|
||||
plugins: [
|
||||
new webpack.optimize.UglifyJsPlugin({
|
||||
include: /\.min\.js$/,
|
||||
minimize: true,
|
||||
sourceMap: true
|
||||
})
|
||||
]
|
||||
optimization: {
|
||||
minimizer: [
|
||||
new UglifyJsPlugin({
|
||||
include: /\.min\.js$/,
|
||||
sourceMap: true
|
||||
})
|
||||
]
|
||||
},
|
||||
plugins: []
|
||||
};
|
||||
|
||||
module.exports = [
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue