From a0bf29ea09d6833e0fcd296e73d2b9678acc93a6 Mon Sep 17 00:00:00 2001 From: Brian Muenzenmeyer Date: Thu, 30 Jul 2026 08:36:22 -0500 Subject: [PATCH] doc: report proper return type on url.format MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Brian Muenzenmeyer PR-URL: https://github.com/nodejs/node/pull/64806 Reviewed-By: Luigi Pinca Reviewed-By: René --- doc/api/url.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/doc/api/url.md b/doc/api/url.md index d5dc06055b6..bdc27144fa3 100644 --- a/doc/api/url.md +++ b/doc/api/url.md @@ -1741,6 +1741,7 @@ changes: * `urlObject` {Object} A URL object (as returned by `url.parse()` or constructed otherwise). +* Returns: {string} The `url.format()` method returns a formatted URL string derived from `urlObject`. @@ -1836,6 +1837,7 @@ changes: * `urlString` {string} A string that will be passed to `url.parse()` and then formatted. +* Returns: {string} `url.format(urlString)` is shorthand for `url.format(url.parse(urlString))`.