diff options
Diffstat (limited to 'packages')
-rw-r--r-- | packages/astro/components/ViewTransitions.astro | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/packages/astro/components/ViewTransitions.astro b/packages/astro/components/ViewTransitions.astro index 05fc57aa6..28a17a09d 100644 --- a/packages/astro/components/ViewTransitions.astro +++ b/packages/astro/components/ViewTransitions.astro @@ -125,6 +125,10 @@ const { fallback = 'animate' } = Astro.props as Props; }; const swap = () => { + // noscript tags inside head element are not honored on swap (#7969). + // Remove them before swapping. + doc.querySelectorAll('head noscript').forEach((el) => el.remove()); + // Swap head for (const el of Array.from(document.head.children)) { const newEl = persistedHeadElement(el); |