url: update WHATWG URL API to latest spec
- Update to spec
- Add opaque hosts
- File state did not correctly deal with lack of base URL
- Cleanup API for file and non-special URLs
- Allow % and IPv6 addresses in non-special URL hosts
- Use specific names for percent-encode sets
- Add empty host concept for file and non-special URLs
- Clarify IPv6 serializer
- Fix existing mistakes
- Add missing ':' to forbidden host code point list.
- Correct IPv4 parser empty label behavior
- Maintain type equivalence in URLContext with spec
- scheme, username, and password should always be strings
- host, port, query, and fragment may be strings or null
- Align scheme state more closely with the spec
- Make sure the `special` variable is always synced with
URL_FLAG_SPECIAL.
PR-URL: https://github.com/nodejs/node/pull/12523
Fixes: https://github.com/nodejs/node/issues/10608
Fixes: https://github.com/nodejs/node/issues/10634
Refs: https://github.com/whatwg/url/pull/185
Refs: https://github.com/whatwg/url/pull/225
Refs: https://github.com/whatwg/url/pull/224
Refs: https://github.com/whatwg/url/pull/218
Refs: https://github.com/whatwg/url/pull/243
Refs: https://github.com/whatwg/url/pull/260
Refs: https://github.com/whatwg/url/pull/268
Reviewed-By:
James M Snell <jasnell@gmail.com>
Reviewed-By:
Daijiro Wachi <daijiro.wachi@gmail.com>
Reviewed-By:
Joyee Cheung <joyeec9h3@gmail.com>
parent
313b2058
Please register or sign in to comment