From 954cadc1e534079a6fba369629272caa173d40ac Mon Sep 17 00:00:00 2001 From: Arsh <69170106+lilnasy@users.noreply.github.com> Date: Mon, 25 Sep 2023 13:43:43 +0000 Subject: [PATCH] fix(deno): do not set vite.ssr.noExternal (#8652) * fix(deno): safely set external specifiers * noExternal does not need to be manually set at all --- .changeset/spotty-dryers-exist.md | 5 +++++ packages/integrations/deno/src/index.ts | 4 +--- 2 files changed, 6 insertions(+), 3 deletions(-) create mode 100644 .changeset/spotty-dryers-exist.md diff --git a/.changeset/spotty-dryers-exist.md b/.changeset/spotty-dryers-exist.md new file mode 100644 index 000000000..c630b1b22 --- /dev/null +++ b/.changeset/spotty-dryers-exist.md @@ -0,0 +1,5 @@ +--- +'@astrojs/deno': patch +--- + +Fixed an issue where deno integration broke some frameworks. diff --git a/packages/integrations/deno/src/index.ts b/packages/integrations/deno/src/index.ts index d1dd6103d..9740e3027 100644 --- a/packages/integrations/deno/src/index.ts +++ b/packages/integrations/deno/src/index.ts @@ -130,6 +130,7 @@ export default function createIntegration(args?: Options): AstroIntegration { `[@astrojs/deno] Otherwise, this adapter is not required to deploy a static site to Deno.` ); } + }, 'astro:build:setup': ({ vite, target }) => { if (target === 'server') { @@ -149,9 +150,6 @@ export default function createIntegration(args?: Options): AstroIntegration { (vite.resolve.alias as Record)[alias.find] = alias.replacement; } } - vite.ssr = { - noExternal: COMPATIBLE_NODE_MODULES, - }; if (Array.isArray(vite.build.rollupOptions.external)) { vite.build.rollupOptions.external.push(DENO_IMPORTS_SHIM);