When using <Script>
with crossorigin
specified, crossorigin
is missing from <link>
that preloads the script
#65879
Labels
bug
Issue was opened via the bug report template.
locked
Script (next/script)
Related to Next.js Script Optimization.
Link to the code that reproduces this issue
https://github.com/mwskwong/missing-cross-origin-from-preload-script
To Reproduce
index.html
, observe the<link>
that preloads the ad sense scripthttps://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js
. Note thatcrossorigin="anonymous"
is missing from<link>
despite it is specified in<Script>
Current vs. Expected behavior
Current
When including a script with
crossOrigin
set:crossorigin
is missing from the<link>
that preloads the script.Expected
For
<link>
,crossorigin
should be set to the same value as that in<Script>
.Provide environment information
Which area(s) are affected? (Select all that apply)
Script (next/script)
Which stage(s) are affected? (Select all that apply)
next dev (local), next build (local), Vercel (Deployed)
Additional context
No response
The text was updated successfully, but these errors were encountered: