diff --git a/packages/vite/src/vite-node.ts b/packages/vite/src/vite-node.ts index 9f3a8e93cc..1713611885 100644 --- a/packages/vite/src/vite-node.ts +++ b/packages/vite/src/vite-node.ts @@ -132,10 +132,7 @@ function createViteNodeApp (ctx: ViteBuildContext, invalidates: Set = ne node.shouldExternalize = async (id: string) => { const result = await isExternal(id) if (result?.external) { - return resolveModule(result.id, { - url: ctx.nuxt.options.modulesDir, - conditions: ['node', 'import', 'require'] - }).catch(() => false) + return resolveModule(result.id, { url: ctx.nuxt.options.modulesDir }).catch(() => false) } return false }