8000 doc: use ASCII apostrophes consistently · nodejs/node@4e9393e · GitHub
[go: up one dir, main page]

Skip to content

Commit 4e9393e

Browse files
tniessenbengl
authored andcommitted
doc: use ASCII apostrophes consistently
PR-URL: #43114 Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Darshan Sen <raisinten@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com> Reviewed-By: Mohammed Keyvanzadeh <mohammadkeyvanzade94@gmail.com>
1 parent 3e89b73 commit 4e9393e

18 files changed

+65
-65
lines changed

SECURITY.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
Report security bugs in Node.js via [HackerOne](https://hackerone.com/nodejs).
66

7-
Your report will be acknowledged within 5 days, and youll receive a more
7+
Your report will be acknowledged within 5 days, and you'll receive a more
88
detailed response to your report within 10 days indicating the next steps in
99
handling your submission.
1010

@@ -49,7 +49,7 @@ Here is the security disclosure policy for Node.js
4949

5050
* This process can take some time, especially when coordination is required
5151
with maintainers of other projects. Every effort will be made to handle the
52-
bug in as timely a manner as possible; however, its important that we follow
52+
bug in as timely a manner as possible; however, it's important that we follow
5353
the release process above to ensure that the disclosure is handled in a
5454
consistent manner.
5555

doc/api/buffer.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -318,7 +318,7 @@ console.log(uint16array);
318318
```
319319

320320
It is possible to create a new `Buffer` that shares the same allocated
321-
memory as a [`TypedArray`][] instance by using the `TypedArray` objects
321+
memory as a [`TypedArray`][] instance by using the `TypedArray` object's
322322
`.buffer` property in the same way. [`Buffer.from()`][`Buffer.from(arrayBuf)`]
323323
behaves like `new Uint8Array()` in this context.
324324

doc/api/console.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -408,7 +408,7 @@ added: v10.0.0
408408

409409
Try to construct a table with the columns of the properties of `tabularData`
410410
(or use `properties`) and rows of `tabularData` and log it. Falls back to just
411-
logging the argument if it cant be parsed as tabular.
411+
logging the argument if it can't be parsed as tabular.
412412

413413
```js
414414
// These can't be parsed as tabular data
@@ -459,7 +459,7 @@ changes:
459459
description: The elapsed time is displayed with a suitable time unit.
460460
- version: v6.0.0
461461
pr-url: https://github.com/nodejs/node/pull/5901
462-
description: This method no longer supports multiple calls that dont map
462+
description: This method no longer supports multiple calls that don't map
463463
to individual `console.time()` calls; see below for details.
464464
-->
465465

doc/api/deprecations.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2569,7 +2569,7 @@ changes:
25692569
Type: Runtime
25702570

25712571
Passing a callback to [`worker.terminate()`][] is deprecated. Use the returned
2572-
`Promise` instead, or a listener to the workers `'exit'` event.
2572+
`Promise` instead, or a listener to the worker's `'exit'` event.
25732573

25742574
### DEP0133: `http` `connection`
25752575

doc/api/esm.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ algorithm][]. All other specifier resolutions are always only resolved with
139139
the standard relative [URL][] resolution semantics.
140140

141141
Like in CommonJS, module files within packages can be accessed by appending a
142-
path to the package name unless the packages [`package.json`][] contains an
142+
path to the package name unless the package's [`package.json`][] contains an
143143
[`"exports"`][] field, in which case files within packages can only be accessed
144144
via the paths defined in [`"exports"`][].
145145

@@ -942,7 +942,7 @@ export function globalPreload({ port }) {
942942
### Examples
943943
944944
The various loader hooks can be used together to accomplish wide-ranging
945-
customizations of Node.js code loading and evaluation behaviors.
945+
customizations of the Node.js code loading and evaluation behaviors.
946946
947947
#### HTTPS loader
948948
@@ -1014,7 +1014,7 @@ prints the current version of CoffeeScript per the module at the URL in
10141014

10151015
#### Transpiler loader
10161016

1017-
Sources that are in formats Node.js doesnt understand can be converted into
1017+
Sources that are in formats Node.js doesn't understand can be converted into
10181018
JavaScript using the [`load` hook][load hook]. Before that hook gets called,
10191019
however, a [`resolve` hook][resolve hook] needs to tell Node.js not to
10201020
throw an error on unknown file types.

doc/api/events.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -813,7 +813,7 @@ stack trace for such warnings.
813813

814814
The emitted warning can be inspected with [`process.on('warning')`][] and will
815815
have the additional `emitter`, `type`, and `count` properties, referring to
816-
the event emitter instance, the events name and the number of attached
816+
the event emitter instance, the event's name and the number of attached
817817
listeners, respectively.
818818
Its `name` property is set to `'MaxListenersExceededWarning'`.
819819

@@ -1633,7 +1633,7 @@ added: v14.5.0
16331633
-->
16341634

16351635
* `event` {Event}
1636-
* Returns: {boolean} `true` if either events `cancelable` attribute value is
1636+
* Returns: {boolean} `true` if either event's `cancelable` attribute value is
16371637
false or its `preventDefault()` method was not invoked, otherwise `false`.
16381638

16391639
Dispatches the `event` to the list of handlers for `event.type`.

doc/api/fs.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2530,7 +2530,7 @@ The "not recommended" examples above check for existence and then use the
25302530
file; the "recommended" examples are better because they use the file directly
25312531
and handle the error, if any.
25322532
2533-
In general, check for the existence of a file only if the file wont be
2533+
In general, check for the existence of a file only if the file won't be
25342534
used directly, for example when its existence is a signal from another
25352535
process.
25362536
@@ -4004,7 +4004,7 @@ If the `target` does not exist, `'file'` will be used. Windows junction points
40044004
require the destination path to be absolute. When using `'junction'`, the
40054005
`target` argument will automatically be normalized to absolute path.
40064006

4007-
Relative targets are relative to the links parent directory.
4007+
Relative targets are relative to the link's parent directory.
40084008
40094009
```mjs
40104010
import { symlink } from 'node:fs';

doc/api/packages.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ in your project's `package.json`.
224224

225225
## Package entry points
226226

227-
In a packages `package.json` file, two fields can define entry points for a
227+
In a package's `package.json` file, two fields can define entry points for a
228228
package: [`"main"`][] and [`"exports"`][]. The [`"main"`][] field is supported
229229
in all versions of Node.js, but its capabilities are limited: it only defines
230230
the main entry point of the package.
@@ -255,7 +255,7 @@ likely be a breaking change.**
255255

256256
To make the introduction of [`"exports"`][] non-breaking, ensure that every
257257
previously supported entry point is exported. It is best to explicitly specify
258-
entry points so that the packages public API is well-defined. For example,
258+
entry points so that the package's public API is well-defined. For example,
259259
a project that previous exported `main`, `lib`,
260260
`feature`, and the `package.json` could use the following `package.exports`:
261261

@@ -303,7 +303,7 @@ path `import feature from 'my-mod/feature/index.js`.
303303
### Main entry point export
304304

305305
To set the main entry point for a package, it is advisable to define both
306-
[`"exports"`][] and [`"main"`][] in the packages [`package.json`][] file:
306+
[`"exports"`][] and [`"main"`][] in the package's [`package.json`][] file:
307307

308308
```json
309309
{
@@ -700,8 +700,8 @@ changes:
700700
description: Unflag self-referencing a package using its name.
701701
-->
702702

703-
Within a package, the values defined in the packages
704-
`package.json` [`"exports"`][] field can be referenced via the packages name.
703+
Within a package, the values defined in the package's
704+
`package.json` [`"exports"`][] field can be referenced via the package's name.
705705
For example, assuming the `package.json` is:
706706

707707
```json
@@ -905,7 +905,7 @@ This approach is appropriate for any of the following use cases:
905905
install both this package and those other packages. For example a `utilities`
906906
package is used directly in an application, and a `utilities-plus` package
907907
adds a few more functions to `utilities`. Because the wrapper exports
908-
underlying CommonJS files, it doesnt matter if `utilities-plus` is written in
908+
underlying CommonJS files, it doesn't matter if `utilities-plus` is written in
909909
CommonJS or ES module syntax; it will work either way.
910910
* The package stores internal state, and the package author would prefer not to
911911
refactor the package to isolate its state management. See the next section.
@@ -915,7 +915,7 @@ be to add an export, e.g. `"./module"`, to point to an all-ES module-syntax
915915
version of the package. This could be used via `import 'pkg/module'` by users
916916
who are certain that the CommonJS version will not be loaded anywhere in the
917917
application, such as by dependencies; or if the CommonJS version can be loaded
918-
but doesnt affect the ES module version (for example, because the package is
918+
but doesn't affect the ES module version (for example, because the package is
919919
stateless):
920920

921921
```json
@@ -949,22 +949,22 @@ points directly:
949949

950950
This can be done if both the CommonJS and ES module versions of the package are
951951
equivalent, for example because one is the transpiled output of the other; and
952-
the packages management of state is carefully isolated (or the package is
952+
the package's management of state is carefully isolated (or the package is
953953
stateless).
954954

955955
The reason that state is an issue is because both the CommonJS and ES module
956956
versions of the package might get used within an application; for example, the
957-
users application code could `import` the ES module version while a dependency
957+
user's application code could `import` the ES module version while a dependency
958958
`require`s the CommonJS version. If that were to occur, two copies of the
959959
package would be loaded in memory and therefore two separate states would be
960960
present. This would likely cause hard-to-troubleshoot bugs.
961961

962-
Aside from writing a stateless package (if JavaScripts `Math` were a package,
962+
Aside from writing a stateless package (if JavaScript's `Math` were a package,
963963
for example, it would be stateless as all of its methods are static), there are
964-
some ways to isolate state so that its shared between the potentially loaded
964+
some ways to isolate state so that it's shared between the potentially loaded
965965
CommonJS and ES module instances of the package:
966966

967-
1. If possible, contain all state within an instantiated object. JavaScripts
967+
1. If possible, contain all state within an instantiated object. JavaScript's
968968
`Date`, for example, needs to be instantiated to contain state; if it were a
969969
package, it would be used like this:
970970

@@ -974,7 +974,7 @@ CommonJS and ES module instances of the package:
974974
// someDate contains state; Date does not
975975
```
976976

977-
The `new` keyword isnt required; a packages function can return a new
977+
The `new` keyword isn't required; a package's function can return a new
978978
object, or modify a passed-in object, to keep the state external to the
979979
package.
980980

@@ -1001,7 +1001,7 @@ CommonJS and ES module instances of the package:
10011001
each reference of `pkg` will contain the same state; and modifying that
10021002
state from either module system will apply to both.
10031003

1004-
Any plugins that attach to the packages singleton would need to separately
1004+
Any plugins that attach to the package's singleton would need to separately
10051005
attach to both the CommonJS and ES module singletons.
10061006

10071007
This approach is appropriate for any of the following use cases:
@@ -1076,7 +1076,7 @@ changes:
10761076
}
10771077
```
10781078

1079-
The `"name"` field defines your packages name. Publishing to the
1079+
The `"name"` field defines your package's name. Publishing to the
10801080
_npm_ registry requires a name that satisfies
10811081
[certain requirements](https://docs.npmjs.com/files/package.json#name).
10821082

@@ -1159,7 +1159,7 @@ Files ending with `.js` are loaded as ES modules when the nearest parent
11591159
`"module"`.
11601160

11611161 8000
The nearest parent `package.json` is defined as the first `package.json` found
1162-
when searching in the current folder, that folders parent, and so on up
1162+
when searching in the current folder, that folder's parent, and so on up
11631163
until a node\_modules folder or the volume root is reached.
11641164

11651165
```json

doc/api/process.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1525,7 +1525,7 @@ added: v0.1.27
15251525
changes:
15261526
- version: v11.14.0
15271527
pr-url: https://github.com/nodejs/node/pull/26544
1528-
description: Worker threads will now use a copy of the parent threads
1528+
description: Worker threads will now use a copy of the parent thread's
15291529
`process.env` by default, configurable through the `env`
15301530
option of the `Worker` constructor.
15311531
- version: v10.0.0
@@ -1648,7 +1648,7 @@ console.log(env.test);
16481648
16491649
Unless explicitly specified when creating a [`Worker`][] instance,
16501650
each [`Worker`][] thread has its own copy of `process.env`, based on its
1651-
parent threads `process.env`, or whatever was specified as the `env` option
1651+
parent thread's `process.env`, or whatever was specified as the `env` option
16521652
to the [`Worker`][] constructor. Changes to `process.env` will not be visible
16531653
across [`Worker`][] threads, and only the main thread can make changes that
16541654
are visible to the operating system or to native add-ons.

doc/api/synopsis.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ Commands in this document start with `$` or `>` to replicate how they would
1919
appear in a user's terminal. Do not include the `$` and `>` characters. They are
2020
there to show the start of each command.
2121

22-
Lines that dont start with `$` or `>` character show the output of the previous
22+
Lines that don't start with `$` or `>` character show the output of the previous
2323
command.
2424

2525
First, make sure to have downloaded and installed Node.js. See

0 commit comments

Comments
 (0)
0