-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathwebpack.prod.js
27 lines (26 loc) · 904 Bytes
/
webpack.prod.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
const UglifyJSPlugin = require('uglifyjs-webpack-plugin');
const merge = require('webpack-merge');
const common = require('./webpack.common.js');
const webpack = require('webpack');
module.exports = merge(common, {
plugins: [
new webpack.DefinePlugin({
'process.env.NODE_ENV': '"production"'
}),
// new webpack.optimize.UglifyJsPlugin({
// mangle: true,
// compress: {
// warnings: false, // Suppress uglification warnings
// pure_getters: true,
// unsafe: true,
// unsafe_comps: true,
// screw_ie8: true
// },
// output: {
// comments: false,
// },
// exclude: [/\.min\.js$/gi] // skip pre-minified libs
// }),
// new webpack.IgnorePlugin(/^\.\/locale$/, [/moment$/])
]
});