Skip to content

Commit ed2ef30

Browse files
committed
exclude server files from optimizeDeps.entries
1 parent 119bff9 commit ed2ef30

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -293,7 +293,7 @@ async function kit({ svelte_config }) {
293293
cors: { preflightContinue: true }
294294
},
295295
optimizeDeps: {
296-
entries: [`${kit.files.routes}/**/+*.{svelte,js,ts}`],
296+
entries: [`${kit.files.routes}/**/+*.{svelte,js,ts}`, `!${kit.files.routes}/**/+*.server.{svelte,js,ts}`],
297297
exclude: [
298298
'@sveltejs/kit',
299299
// exclude kit features so that libraries using them work even when they are prebundled

0 commit comments

Comments
 (0)