From 85bc7d52c674bd661a80c215645e00e9588623fc Mon Sep 17 00:00:00 2001 From: julien huang Date: Sat, 19 Aug 2023 22:56:47 +0200 Subject: [PATCH] fix: only manually chunk client components --- packages/nuxt/src/components/islandsTransform.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/nuxt/src/components/islandsTransform.ts b/packages/nuxt/src/components/islandsTransform.ts index 150de76fa0..f7f36d68ab 100644 --- a/packages/nuxt/src/components/islandsTransform.ts +++ b/packages/nuxt/src/components/islandsTransform.ts @@ -151,7 +151,7 @@ export const componentsChunkPlugin = createUnplugin((options: ComponentChunkOpti config.build.rollupOptions = config.build.rollupOptions || {} config.build.rollupOptions.output = config.build.rollupOptions.output || {} const componentManualChunk = (id: string) => { - if (components.some(c => c.filePath === parseURL(decodeURIComponent(pathToFileURL(id).href)).pathname)) { + if (components.some(c => c.mode !== 'server' && !c.island && c.filePath === parseURL(decodeURIComponent(pathToFileURL(id).href)).pathname)) { return basename(id) } }