You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The link goes to the HTML spec, which refers to mimesniff, which does not define the concept.
I've been trying to find where the behavior of normal @import and stylesheet loading is defined to reject cross-site non-text/css, but haven't found it yet. https://drafts.csswg.org/cssom/#fetch-a-css-style-sheet is a thing, but also uses "Content-Type metadata".
Most simply, what should happen for @import from a constructed stylesheet if the server does not send a Content-Type header?
This probably doesn't need to block this spec progressing, because of the mess the rest of stylesheet loading is, but it might be good to explicitly say the behavior needs to match https://drafts.csswg.org/cssom/#fetch-a-css-style-sheet and whatever HTML uses to load sheets, assuming this last is defined.
Note that I wrote tests in web-platform-tests/wpt#13144 for this, so at least testing-wise it's clear what we want, though we might want to be stricter for constructed style sheets and require an actual text/css match?
The link goes to the HTML spec, which refers to mimesniff, which does not define the concept.
I've been trying to find where the behavior of normal
@import
and stylesheet loading is defined to reject cross-site non-text/css, but haven't found it yet. https://drafts.csswg.org/cssom/#fetch-a-css-style-sheet is a thing, but also uses "Content-Type metadata".Most simply, what should happen for
@import
from a constructed stylesheet if the server does not send aContent-Type
header?This probably doesn't need to block this spec progressing, because of the mess the rest of stylesheet loading is, but it might be good to explicitly say the behavior needs to match https://drafts.csswg.org/cssom/#fetch-a-css-style-sheet and whatever HTML uses to load sheets, assuming this last is defined.
@domenic, @annevk
The text was updated successfully, but these errors were encountered: