Skip to content

Commit d1d412b

Browse files
committed
doc: use sentence-case for headings in docs
PR-URL: nodejs#33889 Refs: https://developers.google.com/style/capitalization#capitalization-in-titles-and-headings Refs: https://docs.microsoft.com/en-us/style-guide/capitalization Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
1 parent 9918bdf commit d1d412b

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+346
-342
lines changed

doc/api/addons.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# C++ Addons
1+
# C++ addons
22

33
<!--introduced_in=v0.10.0-->
44
<!-- type=misc -->
@@ -395,7 +395,7 @@ only the symbols exported by Node.js will be available.
395395
source image. Using this option, the Addon will have access to the full set of
396396
dependencies.
397397

398-
### Loading Addons using `require()`
398+
### Loading addons using `require()`
399399

400400
The filename extension of the compiled Addon binary is `.node` (as opposed
401401
to `.dll` or `.so`). The [`require()`][require] function is written to look for
@@ -410,7 +410,7 @@ there is a file `addon.js` in the same directory as the binary `addon.node`,
410410
then [`require('addon')`][require] will give precedence to the `addon.js` file
411411
and load it instead.
412412

413-
## Native Abstractions for Node.js
413+
## Native abstractions for Node.js
414414

415415
Each of the examples illustrated in this document make direct use of the
416416
Node.js and V8 APIs for implementing Addons. The V8 API can, and has, changed

doc/api/async_hooks.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Async Hooks
1+
# Async hooks
22

33
<!--introduced_in=v8.1.0-->
44

@@ -127,7 +127,7 @@ class MyAddedCallbacks extends MyAsyncCallbacks {
127127
const asyncHook = async_hooks.createHook(new MyAddedCallbacks());
128128
```
129129

130-
##### Error Handling
130+
##### Error handling
131131

132132
If any `AsyncHook` callbacks throw, the application will print the stack trace
133133
and exit. The exit path does follow that of an uncaught exception, but
@@ -201,7 +201,7 @@ be called again until enabled.
201201

202202
For API consistency `disable()` also returns the `AsyncHook` instance.
203203

204-
#### Hook Callbacks
204+
#### Hook callbacks
205205

206206
Key events in the lifetime of asynchronous events have been categorized into
207207
four areas: instantiation, before/after the callback is called, and when the
@@ -628,7 +628,7 @@ only on chained promises. That means promises not created by `then()`/`catch()`
628628
will not have the `before` and `after` callbacks fired on them. For more details
629629
see the details of the V8 [PromiseHooks][] API.
630630

631-
## JavaScript Embedder API
631+
## JavaScript embedder API
632632

633633
Library developers that handle their own asynchronous resources performing tasks
634634
like I/O, connection pooling, or managing callback queues may use the

doc/api/buffer.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ const buf6 = Buffer.from('tést');
5353
const buf7 = Buffer.from('tést', 'latin1');
5454
```
5555

56-
## Buffers and Character Encodings
56+
## Buffers and character encodings
5757
<!-- YAML
5858
changes:
5959
- version: v6.4.0
@@ -2640,7 +2640,7 @@ deprecated: v6.0.0
26402640

26412641
See [`Buffer.allocUnsafeSlow()`][].
26422642

2643-
## Buffer Constants
2643+
## Buffer constants
26442644
<!-- YAML
26452645
added: v8.2.0
26462646
-->

doc/api/child_process.md

+22-22
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Child Process
1+
# Child process
22

33
<!--introduced_in=v0.10.0-->
44

@@ -70,7 +70,7 @@ For certain use cases, such as automating shell scripts, the
7070
the synchronous methods can have significant impact on performance due to
7171
stalling the event loop while spawned processes complete.
7272

73-
## Asynchronous Process Creation
73+
## Asynchronous process creation
7474

7575
The [`child_process.spawn()`][], [`child_process.fork()`][], [`child_process.exec()`][],
7676
and [`child_process.execFile()`][] methods all follow the idiomatic asynchronous
@@ -153,7 +153,7 @@ changes:
153153
* `env` {Object} Environment key-value pairs. **Default:** `process.env`.
154154
* `encoding` {string} **Default:** `'utf8'`
155155
* `shell` {string} Shell to execute the command with. See
156-
[Shell Requirements][] and [Default Windows Shell][]. **Default:**
156+
[Shell requirements][] and [Default Windows shell][]. **Default:**
157157
`'/bin/sh'` on Unix, `process.env.ComSpec` on Windows.
158158
* `timeout` {number} **Default:** `0`
159159
* `maxBuffer` {number} Largest amount of data in bytes allowed on stdout or
@@ -270,8 +270,8 @@ changes:
270270
done on Windows. Ignored on Unix. **Default:** `false`.
271271
* `shell` {boolean|string} If `true`, runs `command` inside of a shell. Uses
272272
`'/bin/sh'` on Unix, and `process.env.ComSpec` on Windows. A different
273-
shell can be specified as a string. See [Shell Requirements][] and
274-
[Default Windows Shell][]. **Default:** `false` (no shell).
273+
shell can be specified as a string. See [Shell requirements][] and
274+
[Default Windows shell][]. **Default:** `false` (no shell).
275275
* `callback` {Function} Called with the output when process terminates.
276276
* `error` {Error}
277277
* `stdout` {string|Buffer}
@@ -355,7 +355,7 @@ changes:
355355
**Default:** `process.execArgv`.
356356
* `serialization` {string} Specify the kind of serialization used for sending
357357
messages between processes. Possible values are `'json'` and `'advanced'`.
358-
See [Advanced Serialization][] for more details. **Default:** `'json'`.
358+
See [Advanced serialization][] for more details. **Default:** `'json'`.
359359
* `silent` {boolean} If `true`, stdin, stdout, and stderr of the child will be
360360
piped to the parent, otherwise they will be inherited from the parent, see
361361
the `'pipe'` and `'inherit'` options for [`child_process.spawn()`][]'s
@@ -434,11 +434,11 @@ changes:
434434
* `gid` {number} Sets the group identity of the process (see setgid(2)).
435435
* `serialization` {string} Specify the kind of serialization used for sending
436436
messages between processes. Possible values are `'json'` and `'advanced'`.
437-
See [Advanced Serialization][] for more details. **Default:** `'json'`.
437+
See [Advanced serialization][] for more details. **Default:** `'json'`.
438438
* `shell` {boolean|string} If `true`, runs `command` inside of a shell. Uses
439439
`'/bin/sh'` on Unix, and `process.env.ComSpec` on Windows. A different
440-
shell can be specified as a string. See [Shell Requirements][] and
441-
[Default Windows Shell][]. **Default:** `false` (no shell).
440+
shell can be specified as a string. See [Shell requirements][] and
441+
[Default Windows shell][]. **Default:** `false` (no shell).
442442
* `windowsVerbatimArguments` {boolean} No quoting or escaping of arguments is
443443
done on Windows. Ignored on Unix. This is set to `true` automatically
444444
when `shell` is specified and is CMD. **Default:** `false`.
@@ -699,7 +699,7 @@ see [V8 issue 7381](https://bugs.chromium.org/p/v8/issues/detail?id=7381).
699699

700700
See also: [`child_process.exec()`][] and [`child_process.fork()`][].
701701

702-
## Synchronous Process Creation
702+
## Synchronous process creation
703703

704704
The [`child_process.spawnSync()`][], [`child_process.execSync()`][], and
705705
[`child_process.execFileSync()`][] methods are synchronous and will block the
@@ -755,8 +755,8 @@ changes:
755755
normally be created on Windows systems. **Default:** `false`.
756756
* `shell` {boolean|string} If `true`, runs `command` inside of a shell. Uses
757757
`'/bin/sh'` on Unix, and `process.env.ComSpec` on Windows. A different
758-
shell can be specified as a string. See [Shell Requirements][] and
759-
[Default Windows Shell][]. **Default:** `false` (no shell).
758+
shell can be specified as a string. See [Shell requirements][] and
759+
[Default Windows shell][]. **Default:** `false` (no shell).
760760
* Returns: {Buffer|string} The stdout from the command.
761761

762762
The `child_process.execFileSync()` method is generally identical to
@@ -804,7 +804,7 @@ changes:
804804
**Default:** `'pipe'`.
805805
* `env` {Object} Environment key-value pairs. **Default:** `process.env`.
806806
* `shell` {string} Shell to execute the command with. See
807-
[Shell Requirements][] and [Default Windows Shell][]. **Default:**
807+
[Shell requirements][] and [Default Windows shell][]. **Default:**
808808
`'/bin/sh'` on Unix, `process.env.ComSpec` on Windows.
809809
* `uid` {number} Sets the user identity of the process. (See setuid(2)).
810810
* `gid` {number} Sets the group identity of the process. (See setgid(2)).
@@ -884,8 +884,8 @@ changes:
884884
**Default:** `'buffer'`.
885885
* `shell` {boolean|string} If `true`, runs `command` inside of a shell. Uses
886886
`'/bin/sh'` on Unix, and `process.env.ComSpec` on Windows. A different
887-
shell can be specified as a string. See [Shell Requirements][] and
888-
[Default Windows Shell][]. **Default:** `false` (no shell).
887+
shell can be specified as a string. See [Shell requirements][] and
888+
[Default Windows shell][]. **Default:** `false` (no shell).
889889
* `windowsVerbatimArguments` {boolean} No quoting or escaping of arguments is
890890
done on Windows. Ignored on Unix. This is set to `true` automatically
891891
when `shell` is specified and is CMD. **Default:** `false`.
@@ -1025,7 +1025,7 @@ message might not be the same as what is originally sent.
10251025
If the `serialization` option was set to `'advanced'` used when spawning the
10261026
child process, the `message` argument can contain data that JSON is not able
10271027
to represent.
1028-
See [Advanced Serialization][] for more details.
1028+
See [Advanced serialization][] for more details.
10291029

10301030
### `subprocess.channel`
10311031
<!-- YAML
@@ -1543,21 +1543,21 @@ This impacts output that includes multibyte character encodings such as UTF-8 or
15431543
UTF-16. For instance, `console.log('中文测试')` will send 13 UTF-8 encoded bytes
15441544
to `stdout` although there are only 4 characters.
15451545

1546-
## Shell Requirements
1546+
## Shell requirements
15471547

15481548
The shell should understand the `-c` switch. If the shell is `'cmd.exe'`, it
15491549
should understand the `/d /s /c` switches and command line parsing should be
15501550
compatible.
15511551

1552-
## Default Windows Shell
1552+
## Default Windows shell
15531553

15541554
Although Microsoft specifies `%COMSPEC%` must contain the path to
15551555
`'cmd.exe'` in the root environment, child processes are not always subject to
15561556
the same requirement. Thus, in `child_process` functions where a shell can be
15571557
spawned, `'cmd.exe'` is used as a fallback if `process.env.ComSpec` is
15581558
unavailable.
15591559

1560-
## Advanced Serialization
1560+
## Advanced serialization
15611561
<!-- YAML
15621562
added:
15631563
- v13.2.0
@@ -1578,7 +1578,7 @@ Therefore, this feature requires opting in by setting the
15781578
`serialization` option to `'advanced'` when calling [`child_process.spawn()`][]
15791579
or [`child_process.fork()`][].
15801580

1581-
[Advanced Serialization]: #child_process_advanced_serialization
1581+
[Advanced serialization]: #child_process_advanced_serialization
15821582
[`'disconnect'`]: process.html#process_event_disconnect
15831583
[`'error'`]: #child_process_event_error
15841584
[`'exit'`]: #child_process_event_exit
@@ -1611,8 +1611,8 @@ or [`child_process.fork()`][].
16111611
[`subprocess.stdio`]: #child_process_subprocess_stdio
16121612
[`subprocess.stdout`]: #child_process_subprocess_stdout
16131613
[`util.promisify()`]: util.html#util_util_promisify_original
1614-
[Default Windows Shell]: #child_process_default_windows_shell
1614+
[Default Windows shell]: #child_process_default_windows_shell
16151615
[HTML structured clone algorithm]: https://developer.mozilla.org/en-US/docs/Web/API/Web_Workers_API/Structured_clone_algorithm
1616-
[Shell Requirements]: #child_process_shell_requirements
1616+
[Shell requirements]: #child_process_shell_requirements
16171617
[synchronous counterparts]: #child_process_synchronous_process_creation
16181618
[v8.serdes]: v8.html#v8_serialization_api

doc/api/cli.md

+8-8
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# Command Line Options
1+
# Command line options
22

33
<!--introduced_in=v5.9.1-->
44
<!--type=misc-->
@@ -162,7 +162,7 @@ added: v12.12.0
162162

163163
> Stability: 1 - Experimental
164164
165-
Enable experimental Source Map V3 support for stack traces.
165+
Enable experimental Source Map v3 support for stack traces.
166166

167167
Currently, overriding `Error.prepareStackTrace` is ignored when the
168168
`--enable-source-maps` flag is set.
@@ -1132,7 +1132,7 @@ added: v0.1.3
11321132

11331133
Print node's version.
11341134

1135-
## Environment Variables
1135+
## Environment variables
11361136

11371137
### `NODE_DEBUG=module[,…]`
11381138
<!-- YAML
@@ -1409,7 +1409,7 @@ easier to instrument applications that call the `child_process.spawn()` family
14091409
of functions. `NODE_V8_COVERAGE` can be set to an empty string, to prevent
14101410
propagation.
14111411

1412-
#### Coverage Output
1412+
#### Coverage output
14131413

14141414
Coverage is output as an array of [ScriptCoverage][] objects on the top-level
14151415
key `result`:
@@ -1426,16 +1426,16 @@ key `result`:
14261426
}
14271427
```
14281428

1429-
#### Source Map Cache
1429+
#### Source map cache
14301430

14311431
> Stability: 1 - Experimental
14321432
1433-
If found, Source Map data is appended to the top-level key `source-map-cache`
1433+
If found, source map data is appended to the top-level key `source-map-cache`
14341434
on the JSON coverage object.
14351435

14361436
`source-map-cache` is an object with keys representing the files source maps
14371437
were extracted from, and values which include the raw source-map URL
1438-
(in the key `url`), the parsed Source Map V3 information (in the key `data`),
1438+
(in the key `url`), the parsed Source Map v3 information (in the key `data`),
14391439
and the line lengths of the source file (in the key `lineLengths`).
14401440

14411441
```json
@@ -1544,7 +1544,7 @@ options are of interest only to V8 developers. Despite this, there is a small
15441544
set of V8 options that are widely applicable to Node.js, and they are
15451545
documented here:
15461546

1547-
### `--max-old-space-size=SIZE` (in Mbytes)
1547+
### `--max-old-space-size=SIZE` (in megabytes)
15481548

15491549
Sets the max memory size of V8's old memory section. As memory
15501550
consumption approaches the limit, V8 will spend more time on

doc/api/cluster.md

+3-3
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ Worker 5644 started
5252

5353
On Windows, it is not yet possible to set up a named pipe server in a worker.
5454

55-
## How It Works
55+
## How it works
5656

5757
<!--type=misc-->
5858

@@ -753,7 +753,7 @@ changes:
753753
`undefined` (inherits from parent process).
754754
* `serialization` {string} Specify the kind of serialization used for sending
755755
messages between processes. Possible values are `'json'` and `'advanced'`.
756-
See [Advanced Serialization for `child_process`][] for more details.
756+
See [Advanced serialization for `child_process`][] for more details.
757757
**Default:** `false`.
758758
* `silent` {boolean} Whether or not to send output to parent's stdio.
759759
**Default:** `false`.
@@ -883,5 +883,5 @@ socket.on('data', (id) => {
883883
[`process` event: `'message'`]: process.html#process_event_message
884884
[`server.close()`]: net.html#net_event_close
885885
[`worker.exitedAfterDisconnect`]: #cluster_worker_exitedafterdisconnect
886-
[Advanced Serialization for `child_process`]: child_process.html#child_process_advanced_serialization
886+
[Advanced serialization for `child_process`]: child_process.html#child_process_advanced_serialization
887887
[Child Process module]: child_process.html#child_process_child_process_fork_modulepath_args_options

doc/api/crypto.md

+9-9
Original file line numberDiff line numberDiff line change
@@ -1579,7 +1579,7 @@ added: v6.3.0
15791579

15801580
* Returns: {Object} An object containing commonly used constants for crypto and
15811581
security related operations. The specific constants currently defined are
1582-
described in [Crypto Constants][].
1582+
described in [Crypto constants][].
15831583

15841584
### `crypto.DEFAULT_ENCODING`
15851585
<!-- YAML
@@ -3045,7 +3045,7 @@ key may be passed for `key`.
30453045

30463046
## Notes
30473047

3048-
### Legacy Streams API (prior to Node.js 0.10)
3048+
### Legacy streams API (prior to Node.js 0.10)
30493049

30503050
The Crypto module was added to Node.js before there was the concept of a
30513051
unified Stream API, and before there were [`Buffer`][] objects for handling
@@ -3056,7 +3056,7 @@ and returned `'latin1'` encoded strings by default rather than `Buffer`s. This
30563056
default was changed after Node.js v0.8 to use [`Buffer`][] objects by default
30573057
instead.
30583058

3059-
### Recent ECDH Changes
3059+
### Recent ECDH changes
30603060

30613061
Usage of `ECDH` with non-dynamically generated key pairs has been simplified.
30623062
Now, [`ecdh.setPrivateKey()`][] can be called with a preselected private key
@@ -3164,12 +3164,12 @@ try {
31643164
console.log(receivedPlaintext);
31653165
```
31663166

3167-
## Crypto Constants
3167+
## Crypto constants
31683168

31693169
The following constants exported by `crypto.constants` apply to various uses of
31703170
the `crypto`, `tls`, and `https` modules and are generally specific to OpenSSL.
31713171

3172-
### OpenSSL Options
3172+
### OpenSSL options
31733173

31743174
<table>
31753175
<tr>
@@ -3325,7 +3325,7 @@ the `crypto`, `tls`, and `https` modules and are generally specific to OpenSSL.
33253325
</tr>
33263326
</table>
33273327

3328-
### OpenSSL Engine Constants
3328+
### OpenSSL engine constants
33293329

33303330
<table>
33313331
<tr>
@@ -3378,7 +3378,7 @@ the `crypto`, `tls`, and `https` modules and are generally specific to OpenSSL.
33783378
</tr>
33793379
</table>
33803380

3381-
### Other OpenSSL Constants
3381+
### Other OpenSSL constants
33823382

33833383
<table>
33843384
<tr>
@@ -3458,7 +3458,7 @@ the `crypto`, `tls`, and `https` modules and are generally specific to OpenSSL.
34583458
</tr>
34593459
</table>
34603460

3461-
### Node.js Crypto Constants
3461+
### Node.js crypto constants
34623462

34633463
<table>
34643464
<tr>
@@ -3528,7 +3528,7 @@ the `crypto`, `tls`, and `https` modules and are generally specific to OpenSSL.
35283528
[AEAD algorithms]: https://en.wikipedia.org/wiki/Authenticated_encryption
35293529
[CCM mode]: #crypto_ccm_mode
35303530
[Caveats]: #crypto_support_for_weak_or_compromised_algorithms
3531-
[Crypto Constants]: #crypto_crypto_constants_1
3531+
[Crypto constants]: #crypto_crypto_constants_1
35323532
[HTML 5.2]: https://www.w3.org/TR/html52/changes.html#features-removed
35333533
[HTML5's `keygen` element]: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/keygen
35343534
[NIST SP 800-131A]: https://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-131Ar1.pdf

0 commit comments

Comments
 (0)