Last active
May 4, 2018 20:12
-
-
Save thescientist13/796501d750b35fc1213ed6ec2052390b to your computer and use it in GitHub Desktop.
webpack optimization API configuration
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
optimization: { | |
minimizer: [ | |
new UglifyJsWebpackPlugin(), | |
new OptimizeCssAssetsPlugin({ | |
cssProcessorOptions: { discardComments: { removeAll: true } } | |
}) | |
], | |
splitChunks: { | |
chunks: 'all', | |
cacheGroups: { | |
styles: { | |
name: 'bundle', | |
test: /\.(css|scss)$/, | |
chunks: 'all', | |
enforce: true | |
} | |
} | |
} | |
}, |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment