Hi,
I found when trying to build my threlte based app for static deployment that I got an error similar to the following: Error [ERR_MODULE_NOT_FOUND]: Cannot find module '<...>/node_modules/three/examples/jsm/postprocessing/EffectComposer' imported from <...>/.svelte-kit/output/server/entries/pages/index.svelte.js Did you mean to import three/examples/jsm/postprocessing/EffectComposer.js?
I saw that in threlte's svelte.config.js there are some extra vite options for threejs. It seems that adding the following "fixes" the issue:
ssr: {
noExternal: ['three']
}
However then index.svelte.js balloons to 1105.56KiB from 63.85KiB. This is not a big deal IMO. However are there any plans/ideas to fix this?
Hi,
I found when trying to build my threlte based app for static deployment that I got an error similar to the following:
Error [ERR_MODULE_NOT_FOUND]: Cannot find module '<...>/node_modules/three/examples/jsm/postprocessing/EffectComposer' imported from <...>/.svelte-kit/output/server/entries/pages/index.svelte.js Did you mean to import three/examples/jsm/postprocessing/EffectComposer.js?I saw that in threlte's svelte.config.js there are some extra vite options for threejs. It seems that adding the following "fixes" the issue:
However then
index.svelte.jsballoons to 1105.56KiB from 63.85KiB. This is not a big deal IMO. However are there any plans/ideas to fix this?