build config

This commit is contained in:
cookfront
2017-02-26 13:34:49 +08:00
parent 7bfc4f4323
commit fc572191cd
4 changed files with 40 additions and 7 deletions

View File

@@ -3,13 +3,15 @@ var webpack = require('webpack');
config.output.filename = config.output.filename.replace(/\.js$/, '.min.js');
delete config.devtool;
config.plugins = [
new webpack.LoaderOptionsPlugin({
minimize: true,
debug: false
}),
new webpack.optimize.UglifyJsPlugin({
sourceMap: false,
drop_console: true,
comments: false,
compress: {
drop_console: true,
warnings: false
}
})