-
Notifications
You must be signed in to change notification settings - Fork 30k
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
doc: clarify treatment of non-string argument to new URL() #41658
Conversation
Co-authored-by: Timothy Gu <[email protected]>
@@ -131,7 +131,7 @@ return `true`. | |||
|
|||
* `input` {string} The absolute or relative input URL to parse. If `input` | |||
is relative, then `base` is required. If `input` is absolute, the `base` | |||
is ignored. | |||
is ignored. If `input` is not a string, it is [converted to a string][] first. | |||
* `base` {string|URL} The base URL to resolve against if the `input` is not |
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.
base
is also USVString
so perhaps this should be {string}
rather than {string|URL}
and also include the note about being converted to a string that is added on line 134 for input
.
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.
base
is alsoUSVString
so perhaps this should be{string}
rather than{string|URL}
and also include the note about being converted to a string that is added on line 134 forinput
.
@TimothyGu @jasnell Sound OK to you?
Commit Queue failed- Loading data for nodejs/node/pull/41658 ✔ Done loading data for nodejs/node/pull/41658 ----------------------------------- PR info ------------------------------------ Title doc: clarify treatment of non-string argument to new URL() (#41658) Author Rich Trott (@Trott) Branch Trott:newurl -> nodejs:master Labels doc, url, author ready Commits 2 - doc: clarify treatment of non-string argument to new URL() - Update doc/api/url.md Committers 2 - Rich Trott - GitHub PR-URL: https://github.com/nodejs/node/pull/41658 Fixes: https://github.com/nodejs/node/issues/41653 Reviewed-By: Richard Lau Reviewed-By: Mohammed Keyvanzadeh Reviewed-By: Luigi Pinca Reviewed-By: Darshan Sen Reviewed-By: Mestery Reviewed-By: Benjamin Gruenbaum ------------------------------ Generated metadata ------------------------------ PR-URL: https://github.com/nodejs/node/pull/41658 Fixes: https://github.com/nodejs/node/issues/41653 Reviewed-By: Richard Lau Reviewed-By: Mohammed Keyvanzadeh Reviewed-By: Luigi Pinca Reviewed-By: Darshan Sen Reviewed-By: Mestery Reviewed-By: Benjamin Gruenbaum -------------------------------------------------------------------------------- ℹ This PR was created on Sun, 23 Jan 2022 00:21:07 GMT ✔ Approvals: 6 ✔ - Richard Lau (@richardlau) (TSC): https://github.com/nodejs/node/pull/41658#pullrequestreview-860252993 ✔ - Mohammed Keyvanzadeh (@VoltrexMaster): https://github.com/nodejs/node/pull/41658#pullrequestreview-860254672 ✔ - Luigi Pinca (@lpinca): https://github.com/nodejs/node/pull/41658#pullrequestreview-860283743 ✔ - Darshan Sen (@RaisinTen) (TSC): https://github.com/nodejs/node/pull/41658#pullrequestreview-860316074 ✔ - Mestery (@Mesteery): https://github.com/nodejs/node/pull/41658#pullrequestreview-860318289 ✔ - Benjamin Gruenbaum (@benjamingr): https://github.com/nodejs/node/pull/41658#pullrequestreview-861643651 ✔ Last GitHub CI successful ℹ Green GitHub CI is sufficient -------------------------------------------------------------------------------- ✔ No git cherry-pick in progress ✔ No git am in progress ✔ No git rebase in progress -------------------------------------------------------------------------------- - Bringing origin/master up to date... From https://github.com/nodejs/node * branch master -> FETCH_HEAD ✔ origin/master is now up-to-date - Downloading patch for 41658 From https://github.com/nodejs/node * branch refs/pull/41658/merge -> FETCH_HEAD ✔ Fetched commits as b27ae24dcc42..ff5b5a438465 -------------------------------------------------------------------------------- [master fb622bf670] doc: clarify treatment of non-string argument to new URL() Author: Rich Trott Date: Sat Jan 22 16:18:30 2022 -0800 1 file changed, 3 insertions(+), 2 deletions(-) [master 93ce1361e9] Update doc/api/url.md Author: Rich Trott Date: Sat Jan 22 22:30:00 2022 -0800 1 file changed, 1 insertion(+), 1 deletion(-) ✔ Patches applied There are 2 commits in the PR. Attempting autorebase. Rebasing (2/4)https://github.com/nodejs/node/actions/runs/1743119502 |
Landed in 88a3bd5 |
Closes: nodejs#41653 PR-URL: nodejs#41658 Fixes: nodejs#41653 Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Mohammed Keyvanzadeh <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Darshan Sen <[email protected]> Reviewed-By: Mestery <[email protected]> Reviewed-By: Benjamin Gruenbaum <[email protected]>
Closes: #41653 PR-URL: #41658 Fixes: #41653 Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Mohammed Keyvanzadeh <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Darshan Sen <[email protected]> Reviewed-By: Mestery <[email protected]> Reviewed-By: Benjamin Gruenbaum <[email protected]>
Closes: #41653 PR-URL: #41658 Fixes: #41653 Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Mohammed Keyvanzadeh <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Darshan Sen <[email protected]> Reviewed-By: Mestery <[email protected]> Reviewed-By: Benjamin Gruenbaum <[email protected]>
Closes: #41653 PR-URL: #41658 Fixes: #41653 Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Mohammed Keyvanzadeh <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Darshan Sen <[email protected]> Reviewed-By: Mestery <[email protected]> Reviewed-By: Benjamin Gruenbaum <[email protected]>
Closes: #41653 PR-URL: #41658 Fixes: #41653 Reviewed-By: Richard Lau <[email protected]> Reviewed-By: Mohammed Keyvanzadeh <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Darshan Sen <[email protected]> Reviewed-By: Mestery <[email protected]> Reviewed-By: Benjamin Gruenbaum <[email protected]>
Closes: #41653