From a8a43a920332e815bec7b4bcb2ba0f59c06990a3 Mon Sep 17 00:00:00 2001 From: Daniel Roe Date: Tue, 21 Jan 2025 16:17:30 +0000 Subject: [PATCH] fix(vite): inline shared folder in dev mode (#30690) --- packages/vite/src/vite-node.ts | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/packages/vite/src/vite-node.ts b/packages/vite/src/vite-node.ts index ee29478ea1..28c9e04bbd 100644 --- a/packages/vite/src/vite-node.ts +++ b/packages/vite/src/vite-node.ts @@ -6,9 +6,8 @@ import { isAbsolute, join, normalize, resolve } from 'pathe' // import { addDevServerHandler } from '@nuxt/kit' import { isFileServingAllowed } from 'vite' import type { ModuleNode, Plugin as VitePlugin } from 'vite' -import { getQuery, withTrailingSlash } from 'ufo' +import { getQuery } from 'ufo' import { normalizeViteManifest } from 'vue-bundle-renderer' -import escapeStringRegexp from 'escape-string-regexp' import { distDir } from './dirs' import type { ViteBuildContext } from './vite' import { isCSS } from './utils' @@ -120,10 +119,6 @@ function createViteNodeApp (ctx: ViteBuildContext, invalidates: Set = ne /^#/, /\?/, ], - external: [ - '#shared', - new RegExp('^' + escapeStringRegexp(withTrailingSlash(resolve(ctx.nuxt.options.rootDir, ctx.nuxt.options.dir.shared)))), - ], }, transformMode: { ssr: [/.*/],