Authored by 毕凯

去除第三方混淆插件

... ... @@ -128,7 +128,6 @@
"webpack-dev-server": "^2.7.1",
"webpack-hot-middleware": "^2.19.1",
"webpack-merge": "^4.1.0",
"webpack-uglify-parallel": "^0.1.3",
"yoho-cookie": "^1.2.0",
"yoho-fastclick": "^1.0.6",
"yoho-hammer": "^2.0.7",
... ...
'use strict';
const os = require('os');
const path = require('path');
const shelljs = require('shelljs');
const webpack = require('webpack');
const merge = require('webpack-merge');
const UglifyJsParallelPlugin = require('webpack-uglify-parallel');
const ExtractTextPlugin = require('extract-text-webpack-plugin');
const config = require('../../package.json');
const distDir = path.join(__dirname, `../dist/${config.name}/${config.version}`);
... ... @@ -30,12 +28,14 @@ module.exports = merge(baseConfig, {
NODE_ENV: '"production"'
}
}),
new UglifyJsParallelPlugin({
workers: os.cpus().length,
compress: {
warnings: false
},
comments: false
new webpack.optimize.UglifyJsPlugin({
parallel: true,
uglifyOptions: {
compress: {
warnings: false
},
comments: false
}
})
]
});
... ...