docs: add experimentalMinChunkSize to migration guide#21892
docs: add experimentalMinChunkSize to migration guide#21892o-m12a wants to merge 3 commits intovitejs:mainfrom
Conversation
Co-Authored-By: Claude Opus 4.6 <[email protected]>
|
Tried the suggested fix on Vite 8.0.1, and it doesn't work. import { defineConfig } from 'vite';
const defaultConfig = defineConfig({
build: {
sourcemap: 'hidden',
assetsInlineLimit: 0,
rolldownOptions: {
output: {
codeSplitting: {
minSize: 200_000
}
}
}
// rollupOptions: {
// output: {
// experimentalMinChunkSize: 2000
// }
// }
}
});
export default defaultConfig; |
minSize only takes effect when groups are defined, so it is not a direct replacement for experimentalMinChunkSize. Co-Authored-By: Claude Opus 4.6 <[email protected]>
|
@Perdolique Thanks for testing this! You're right — I've confirmed that
This means See also: rolldown/rolldown#4932 |
|
@o-m12a I guess it's not even close to being a replacement. The purpose of the |
Co-Authored-By: Claude Opus 4.6 <[email protected]>
|
@Perdolique That's a fair point — For tracking automatic chunk merging support in Rolldown, see rolldown/rolldown#4788. |
|
Ahh, alright. Then it's probably the feature, not the documentation bug, from my perspective. It's only the blocker at the moment for switching us from Vite v7 to v8. I'll track the rolldown issue. |
This is a docs-only change with no runtime impact.
Summary
Add
build.rollupOptions.output.experimentalMinChunkSizeto the v7 → v8 migration guide, noting its removal and that there is no direct equivalent in Rolldown. Points to thecodeSplittingoption as the general area for controlling chunk splitting.Placed after the
manualChunkssection, as both are Rollupoutput→ RolldowncodeSplittingmigrations.What I confirmed
pnpm run docs-buildpassescodeSplittingAPI reference resolves correctlycodeSplitting.minSizewithoutgroupshas no effect (Rolldown emits a warning)codeSplittingwithgroupsis not a direct 1:1 replacement forexperimentalMinChunkSizeFixes #21844