-
Notifications
You must be signed in to change notification settings - Fork 18
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
WHATWG URL compliance #4
Comments
Why? |
Because it's only going to get more popular with time. http/https modules support them in Node 8.x. They also parse at least 2x faster. |
My library is already compatible with WHATWG URLs, the exported function behaves identical regardless of whether the input is a WHATWG URL or a legacy (Node.js) URL. The return value is a string. If the consumer really wants to have a URL, it is trivial to do So, I don't see a benefit in adding "universal-url" as a dependency. |
I was referring to the internal use of |
Better in what sense? I don't see a functional difference between the two parsers in my use case. I only use scheme ( There must be a compelling reason before I add new dependencies. The only potential advantage that you've mentioned so far is a "at least 2x faster". I don't attribute much value to this claim, not only because of the lack of benchmarks, but mainly because the existing implementation is already sufficiently fast and unlikely to be a bottleneck for performance issues. |
The specification uses TR46 to parse IDNA host names. Benchmarks: nodejs/node#10678 (comment) |
Should probably switch the legacy |
via universal-url
The text was updated successfully, but these errors were encountered: