From d80ff1385d2370934900ca9714ceb7057a5be884 Mon Sep 17 00:00:00 2001 From: Mike McCready <66998419+MikeMcC399@users.noreply.github.com> Date: Wed, 25 Feb 2026 10:27:54 +0100 Subject: [PATCH 1/3] doc: include url.resolve() in DEP0169 application deprecation Mark url.resolve() as deprecated Update also DEP0116 with cross-reference to DEP0169 --- doc/api/deprecations.md | 9 +++++++-- doc/api/url.md | 6 ++++++ 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/doc/api/deprecations.md b/doc/api/deprecations.md index 7e6347927962b2..4da031cb4d326b 100644 --- a/doc/api/deprecations.md +++ b/doc/api/deprecations.md @@ -2660,11 +2660,15 @@ future release. +> Stability: 0 - Deprecated: Use the WHATWG URL API instead. + * `from` {string} The base URL to use if `to` is a relative URL. * `to` {string} The target URL to resolve. From bd5393ff081a49f12dd44468c53887d694416808 Mon Sep 17 00:00:00 2001 From: Mike McCready <66998419+MikeMcC399@users.noreply.github.com> Date: Thu, 26 Feb 2026 11:42:11 +0100 Subject: [PATCH 2/3] add reason for url.resolve deprecation --- doc/api/url.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/doc/api/url.md b/doc/api/url.md index 1eb3874981d55a..0c3b85346ff000 100644 --- a/doc/api/url.md +++ b/doc/api/url.md @@ -1839,7 +1839,7 @@ changes: `url.format(urlString)` is shorthand for `url.format(url.parse(urlString))`. -Because it invokes the deprecated [`url.parse()`][], passing a string argument +Because it invokes the deprecated [`url.parse()`][] internally, passing a string argument to `url.format()` is itself deprecated. Canonicalizing a URL string can be performed using the WHATWG URL API, by @@ -1988,6 +1988,8 @@ changes: * `from` {string} The base URL to use if `to` is a relative URL. * `to` {string} The target URL to resolve. +Because it invokes the deprecated [`url.parse()`][] internally, `url.resolve()` is itself deprecated. + The `url.resolve()` method resolves a target URL relative to a base URL in a manner similar to that of a web browser resolving an anchor tag. From 28196da4b42d2e0378a178d57d97865b720e0878 Mon Sep 17 00:00:00 2001 From: Mike McCready <66998419+MikeMcC399@users.noreply.github.com> Date: Thu, 26 Feb 2026 13:03:44 +0100 Subject: [PATCH 3/3] move added sentence downwards --- doc/api/url.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/api/url.md b/doc/api/url.md index 0c3b85346ff000..d5dc06055b6cc3 100644 --- a/doc/api/url.md +++ b/doc/api/url.md @@ -1988,8 +1988,6 @@ changes: * `from` {string} The base URL to use if `to` is a relative URL. * `to` {string} The target URL to resolve. -Because it invokes the deprecated [`url.parse()`][] internally, `url.resolve()` is itself deprecated. - The `url.resolve()` method resolves a target URL relative to a base URL in a manner similar to that of a web browser resolving an anchor tag. @@ -2000,6 +1998,8 @@ url.resolve('http://example.com/', '/one'); // 'http://example.com/one' url.resolve('http://example.com/one', '/two'); // 'http://example.com/two' ``` +Because it invokes the deprecated [`url.parse()`][] internally, `url.resolve()` is itself deprecated. + To achieve the same result using the WHATWG URL API: ```js