Skip to content

Commit bf15fe0

Browse files
committed
add manual chunks again
1 parent abcb7c0 commit bf15fe0

File tree

1 file changed

+1
-13
lines changed

1 file changed

+1
-13
lines changed

packages/kit/src/exports/vite/index.js

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -695,6 +695,7 @@ Tips:
695695
assetFileNames: `${prefix}/assets/[name].[hash][extname]`,
696696
hoistTransitiveImports: false,
697697
sourcemapIgnoreList,
698+
manualChunks: split ? undefined : () => 'bundle',
698699
inlineDynamicImports: false
699700
},
700701
preserveEntrySignatures: 'strict',
@@ -734,19 +735,6 @@ Tips:
734735
// enableNativePlugin: true
735736
// }
736737
};
737-
738-
if (!split && new_config.build?.rollupOptions?.output) {
739-
const output_options = /** @type {import('vite').Rollup.OutputOptions} */ (
740-
new_config.build.rollupOptions.output
741-
);
742-
// @ts-expect-error `vite.rolldownVersion` only exists in `rolldown-vite`
743-
if (vite.rolldownVersion) {
744-
output_options.inlineDynamicImports = true;
745-
} else {
746-
/** @type {import('rollup').OutputOptions} */ (output_options).manualChunks = () =>
747-
'bundle';
748-
}
749-
}
750738
} else {
751739
new_config = {
752740
appType: 'custom',

0 commit comments

Comments
 (0)