diff --git a/.changeset/dirty-bags-double.md b/.changeset/dirty-bags-double.md new file mode 100644 index 000000000000..9c5f3e99302e --- /dev/null +++ b/.changeset/dirty-bags-double.md @@ -0,0 +1,5 @@ +--- +'astro': patch +--- + +Fixes an issue with cssesc in dev mode when setting `vite.ssr.noExternal: true` diff --git a/packages/astro/src/core/create-vite.ts b/packages/astro/src/core/create-vite.ts index f3174b5d325c..87574eda2d18 100644 --- a/packages/astro/src/core/create-vite.ts +++ b/packages/astro/src/core/create-vite.ts @@ -71,6 +71,8 @@ const ONLY_DEV_EXTERNAL = [ 'prismjs/components/index.js', // Imported by `astro/assets` -> `packages/astro/src/core/logger/core.ts` 'string-width', + // Imported by `astro:transitions` -> packages/astro/src/runtime/server/transition.ts + 'cssesc', ]; /** Return a base vite config as a common starting point for all Vite commands. */