webpack打包过滤console.log
在webpack.prod.conf.js里面的plugins里面加上
drop_debugger: true,
drop_console: true
new webpack.optimize.UglifyJsPlugin({ compress: { warnings: false, drop_debugger: true, drop_console: true }, sourceMap: true }),
参考链接 https://webpack.js.org/configuration/plugins/