diff --git a/packages/vite/src/vite.ts b/packages/vite/src/vite.ts index 9df36347bc..cb02b4113c 100644 --- a/packages/vite/src/vite.ts +++ b/packages/vite/src/vite.ts @@ -26,7 +26,7 @@ export async function bundle (nuxt: Nuxt) { config: vite.mergeConfig( nuxt.options.vite as any || {}, { - root: nuxt.options.rootDir, + root: nuxt.options.srcDir, mode: nuxt.options.dev ? 'development' : 'production', logLevel: 'warn', define: {