summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--package.json3
-rw-r--r--webpack.production.js15
2 files changed, 11 insertions, 7 deletions
diff --git a/package.json b/package.json
index 74de2c80..d5e8e55c 100644
--- a/package.json
+++ b/package.json
@@ -163,6 +163,7 @@
"script-loader": "^0.7.0",
"style-loader": "^0.13.1",
"url-loader": "^0.5.7",
- "webpack": "^1.14.0"
+ "webpack": "^1.14.0",
+ "webpack-parallel-uglify-plugin": "^0.2.0"
}
}
diff --git a/webpack.production.js b/webpack.production.js
index b28c34ae..7c690d28 100644
--- a/webpack.production.js
+++ b/webpack.production.js
@@ -3,6 +3,7 @@ var webpack = require('webpack');
var path = require('path');
var ExtractTextPlugin = require("extract-text-webpack-plugin");
var OptimizeCssAssetsPlugin = require('optimize-css-assets-webpack-plugin');
+var ParallelUglifyPlugin = require('webpack-parallel-uglify-plugin');
module.exports = [Object.assign({}, baseConfig, {
plugins: baseConfig.plugins.concat([
@@ -11,12 +12,14 @@ module.exports = [Object.assign({}, baseConfig, {
'NODE_ENV': JSON.stringify('production')
}
}),
- new webpack.optimize.UglifyJsPlugin({
- compress: {
- warnings: false
- },
- mangle: false,
- sourceMap: false
+ new ParallelUglifyPlugin({
+ uglifyJS: {
+ compress: {
+ warnings: false
+ },
+ mangle: false,
+ sourceMap: false
+ }
}),
new ExtractTextPlugin("[name].[hash].css")
]),