diff --git a/.changeset/shaky-queens-know.md b/.changeset/shaky-queens-know.md new file mode 100644 index 000000000000..20b4d8221b16 --- /dev/null +++ b/.changeset/shaky-queens-know.md @@ -0,0 +1,5 @@ +--- +'astro': patch +--- + +Fixes a dev server error where an SSR full reload triggered by a third-party Vite plugin (such as `@tailwindcss/vite`) could fail with `Failed to load url astro:server-app.js` diff --git a/packages/astro/src/vite-plugin-app/index.ts b/packages/astro/src/vite-plugin-app/index.ts index 1989468ee2a2..c5da519168cc 100644 --- a/packages/astro/src/vite-plugin-app/index.ts +++ b/packages/astro/src/vite-plugin-app/index.ts @@ -2,7 +2,7 @@ import type * as vite from 'vite'; const ASTRO_APP_ID = 'virtual:astro:app'; const RESOLVED_ASTRO_APP_ID = '\0' + ASTRO_APP_ID; -export const ASTRO_DEV_SERVER_APP_ID = 'astro:server-app'; +export const ASTRO_DEV_SERVER_APP_ID = 'virtual:astro:server-app'; export function vitePluginApp(): vite.Plugin[] { let command: vite.ResolvedConfig['command'];