routes bundle
This commit is contained in:
@@ -162,6 +162,15 @@ export default defineConfig(({ command }) => ({
|
||||
output: {
|
||||
codeSplitting: {
|
||||
groups: [
|
||||
{
|
||||
// Consolidate every lazy(() => import('./pages/...')) route
|
||||
// module into ONE chunk so we don't ship ~30 tiny 0.1–0.4 kB
|
||||
// files. Still loaded on first route navigation (not on the
|
||||
// initial bundle). For per-section chunks instead, replace this
|
||||
// with groups matching /\/src\/pages\/(artikel|lieferung|...)\//.
|
||||
name: 'routes',
|
||||
test: /\/src\/pages\//,
|
||||
},
|
||||
{
|
||||
name: 'react-vendor',
|
||||
test: /node_modules\/(react|react-dom|react-router|react-router-dom|scheduler)\//,
|
||||
|
||||
Reference in New Issue
Block a user