diff --git a/src/rollup/config.ts b/src/rollup/config.ts index c72b68bb6b..eb29be0d98 100644 --- a/src/rollup/config.ts +++ b/src/rollup/config.ts @@ -280,7 +280,7 @@ export const plugins = [ extensions, preferBuiltins: true, rootDir: nitro.options.rootDir, - moduleDirectories: nitro.options.nodeModulesDirs, + moduleDirectories: ['node_modules'].concat(nitro.options.nodeModulesDirs), // 'module' is intentionally not supported because of externals mainFields: ['main'], exportConditions: [