I am using the following snippets while building my react based application with webpack. I need to restrict the max line length of the output file to 7000 characters and the below config helps do it except if there is a CSS line in the bundle. The CSS line comes in a string literal and it goes beyond this restriction. How do I make the restriction applied to CSS embedded within the bundle?
new Webpack.optimize.UglifyJsPlugin({
compress: {
warnings: false
},
output: {
comments: false,
max_line_len: 7000
},
sourceMap: false
})
A task which is used during the build from npm -
UglifyJS.minify([ ... ], {
output: {
max_line_len: 7000
}
});