Created
June 7, 2019 04:00
-
-
Save quantizor/26b988690f3c9951a02b8ad85bf78974 to your computer and use it in GitHub Desktop.
optimize nextjs webpack config
This file contains hidden or 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
module.exports = { | |
webpack: config => { | |
if (config.mode === 'production' && config.name === 'client') { | |
config.optimization.splitChunks.cacheGroups.commons.minChunks = 2; | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment