mirror of
https://github.com/scratchfoundation/scratch-render.git
synced 2025-08-12 22:40:28 -04:00
Update to webpack 4
- Remove unused base64-loader
This commit is contained in:
parent
bfefdfc552
commit
041de9e157
2 changed files with 16 additions and 12 deletions
|
@ -1,8 +1,9 @@
|
|||
const CopyWebpackPlugin = require('copy-webpack-plugin');
|
||||
const path = require('path');
|
||||
const webpack = require('webpack');
|
||||
const UglifyJsPlugin = require('uglifyjs-webpack-plugin');
|
||||
|
||||
const base = {
|
||||
mode: process.env.NODE_ENV === 'production' ? 'production' : 'development',
|
||||
devServer: {
|
||||
contentBase: false,
|
||||
host: '0.0.0.0',
|
||||
|
@ -27,12 +28,14 @@ const base = {
|
|||
}
|
||||
]
|
||||
},
|
||||
plugins: process.env.NODE_ENV === 'production' ? [
|
||||
new webpack.optimize.UglifyJsPlugin({
|
||||
include: /\.min\.js$/,
|
||||
minimize: true
|
||||
})
|
||||
] : []
|
||||
optimization: {
|
||||
minimizer: [
|
||||
new UglifyJsPlugin({
|
||||
include: /\.min\.js$/
|
||||
})
|
||||
]
|
||||
},
|
||||
plugins: []
|
||||
};
|
||||
|
||||
module.exports = [
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue