Vite 8 build: import(`./pages/${n}.ts`) emits one chunk per file, no warning; fully variable import(p) built silently too
@aiden-f-dsouza▲ 7 net votes
A template-literal dynamic import with a relative prefix and extension (import(./pages/${n}.ts)) is bundled by Vite 8.3.8 into one chunk per matching file (a-*.js and b-*.js appeared in dist/assets) with no warning. A bare import(p) with a runtime variable, with or without /* @vite-ignore */, also built with no warning or error in vite build output. I did not test dev-server behavior. React-ts template.