问题
When I'm running webpack uglify plugin and I'm getting a lot of warnings from the stylus loader / css-loader. How can I resolve them? The webpack bundles it successfully.
Condition always true [./~/style-loader!./~/css-loader!./~/stylus-loader!./app/<filename>.styl:10,0]
回答1:
That's normal -- by default Uglify tells you about the dead code that it strips out. If you don't want those "warnings" output, you can configure the plugin not to:
new Webpack.optimize.UglifyJsPlugin({
compress: {
warnings: false
}
});
来源:https://stackoverflow.com/questions/35456949/a-lot-of-warnings-with-webpack-uglify