Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit aedbfdb

Browse filesBrowse files
TrottMylesBorins
authored andcommitted
doc: standardize on "host name" in url.md
Our docs have a mix of "hostname" and "host name" in prose. Let's follow the usage of Unix man pages, RFCs, and most professionally-edited sources, and use "host name" in prose and "hostname" to refer to the command and in code. Lint rule forthcoming. PR-URL: #31326 Refs: #31073 Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Richard Lau <riclau@uk.ibm.com> Reviewed-By: James M Snell <jasnell@gmail.com> Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
1 parent 2824527 commit aedbfdb
Copy full SHA for aedbfdb

File tree

Expand file treeCollapse file tree

1 file changed

+5
-5
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+5
-5
lines changed
Open diff view settings
Collapse file

‎doc/api/url.md‎

Copy file name to clipboardExpand all lines: doc/api/url.md
+5-5Lines changed: 5 additions & 5 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ const myURL = new URL({ toString: () => 'https://example.org/' });
114114
// https://example.org/
115115
```
116116

117-
Unicode characters appearing within the hostname of `input` will be
117+
Unicode characters appearing within the host name of `input` will be
118118
automatically converted to ASCII using the [Punycode][] algorithm.
119119

120120
```js
@@ -192,7 +192,7 @@ Invalid host values assigned to the `host` property are ignored.
192192

193193
* {string}
194194

195-
Gets and sets the hostname portion of the URL. The key difference between
195+
Gets and sets the host name portion of the URL. The key difference between
196196
`url.host` and `url.hostname` is that `url.hostname` does *not* include the
197197
port.
198198

@@ -206,7 +206,7 @@ console.log(myURL.href);
206206
// Prints https://example.com:81/foo
207207
```
208208

209-
Invalid hostname values assigned to the `hostname` property are ignored.
209+
Invalid host name values assigned to the `hostname` property are ignored.
210210

211211
#### `url.href`
212212

@@ -1298,8 +1298,8 @@ path of most URLs. The *fragment percent-encode set* is used for URL fragments.
12981298
The *C0 control percent-encode set* is used for host and path under certain
12991299
specific conditions, in addition to all other cases.
13001300

1301-
When non-ASCII characters appear within a hostname, the hostname is encoded
1302-
using the [Punycode][] algorithm. Note, however, that a hostname *may* contain
1301+
When non-ASCII characters appear within a host name, the host name is encoded
1302+
using the [Punycode][] algorithm. Note, however, that a host name *may* contain
13031303
*both* Punycode encoded and percent-encoded characters:
13041304

13051305
```js

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.