-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use a more common serialization for MIME types #86
Conversation
This is a defense-in-depth for the issues that arised at #84. In theory they are all solved by whatwg/xhr#224, but given how quickly several sites turned up that relied on a space, it seems prudent to standardize on that serialization to avoid similar issues elsewhere.
cc @wisniewskit |
…ialization Tests for whatwg/xhr#224 and whatwg/mimesniff#86. They are combined in a single commit as otherwise there would be two rounds of changes to the XMLHttpRequest tests, while they are really supposed to be coupled.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm curious to what extent this is more or less compatible with what browsers do today in non-overrideMimeType contexts. But, editorially LGTM.
The issues are not due to |
Yeah, if the only other case where browsers serialize (or should serialize) is blobs, then I guess this will probably work out ok. |
…ialization Tests for whatwg/xhr#224 and whatwg/mimesniff#86. They are combined in a single commit as otherwise there would be two rounds of changes to the XMLHttpRequest tests, while they are really supposed to be coupled.
As noted in web-platform-tests/wpt#13544 (comment) I'm no longer convinced we should do this. The XMLHttpRequest change addresses all known issues, so let's keep the MIME type serializer stable for now. |
Shall we close this then? I'll note that the original implementation in jsdom actually included the inter-segment whitespace in the parsed data structure, for this sort of reason :( |
Yeah, let's close this. To your aside, if sites actually depend on that they might depend on much more (such as |
This is a defense-in-depth for the issues that arised at #84. In theory they are all solved by whatwg/xhr#224, but given how quickly several sites turned up that relied on a space, it seems prudent to standardize on that serialization to avoid similar issues elsewhere.
Preview | Diff