Commit 6b694a50 authored by Tim Neutkens's avatar Tim Neutkens

Temporarily disable commonschunk

parent 5563c200
...@@ -99,17 +99,17 @@ function optimizationConfig ({dir, dev, isServer, totalPages}) { ...@@ -99,17 +99,17 @@ function optimizationConfig ({dir, dev, isServer, totalPages}) {
// Only enabled in production // Only enabled in production
// This logic will create a commons bundle // This logic will create a commons bundle
// with modules that are used in 50% of all pages // with modules that are used in 50% of all pages
config.splitChunks.chunks = 'all' // config.splitChunks.chunks = 'all'
config.splitChunks.cacheGroups.commons = { // config.splitChunks.cacheGroups.commons = {
name: 'commons', // name: 'commons',
chunks: 'all', // chunks: 'all',
minChunks: totalPages > 2 ? totalPages * 0.5 : 2 // minChunks: totalPages > 2 ? totalPages * 0.5 : 2
} // }
config.splitChunks.cacheGroups.react = { // config.splitChunks.cacheGroups.react = {
name: 'commons', // name: 'commons',
chunks: 'all', // chunks: 'all',
test: /[\\/]node_modules[\\/](react|react-dom)[\\/]/ // test: /[\\/]node_modules[\\/](react|react-dom)[\\/]/
} // }
return config return config
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment