Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

doc: fix typos #55066

Merged
merged 2 commits into from
Sep 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion doc/api/crypto.md
Original file line number Diff line number Diff line change
Expand Up @@ -5968,7 +5968,7 @@ See the [list of SSL OP Flags][] for details.
</tr>
<tr>
<td><code>ENGINE_METHOD_PKEY_METHS</code></td>
<td>Limit engine usage to PKEY_METHDS</td>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is not a typo per se, it comes from an upstream dependency

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

<td>Limit engine usage to PKEY_METHS</td>
</tr>
<tr>
<td><code>ENGINE_METHOD_PKEY_ASN1_METHS</code></td>
Expand Down
16 changes: 8 additions & 8 deletions doc/api/module.md
Original file line number Diff line number Diff line change
Expand Up @@ -142,22 +142,22 @@ If `cacheDir` is not specified, Node.js will either use the directory specified
[`NODE_COMPILE_CACHE=dir`][] environment variable if it's set, or use
`path.join(os.tmpdir(), 'node-compile-cache')` otherwise. For general use cases, it's
recommended to call `module.enableCompileCache()` without specifying the `cacheDir`,
so that the directory can be overriden by the `NODE_COMPILE_CACHE` environment
so that the directory can be overridden by the `NODE_COMPILE_CACHE` environment
variable when necessary.

Since compile cache is supposed to be a quiet optimization that is not required for the
application to be functional, this method is designed to not throw any exception when the
compile cache cannot be enabled. Instead, it will return an object containing an error
message in the `message` field to aid debugging.
If compile cache is enabled successefully, the `directory` field in the returned object
If compile cache is enabled successfully, the `directory` field in the returned object
contains the path to the directory where the compile cache is stored. The `status`
field in the returned object would be one of the `module.constants.compileCacheStatus`
values to indicate the result of the attempt to enable the [module compile cache][].

This method only affects the current Node.js instance. To enable it in child worker threads,
either call this method in child worker threads too, or set the
`process.env.NODE_COMPILE_CACHE` value to compile cache directory so the behavior can
be inheritend into the child workers. The directory can be obtained either from the
be inherited into the child workers. The directory can be obtained either from the
`directory` field returned by this method, or with [`module.getCompileCacheDir()`][].

#### Module compile cache
Expand Down Expand Up @@ -264,7 +264,7 @@ changes:
**Default:** `'data:'`
* `data` {any} Any arbitrary, cloneable JavaScript value to pass into the
[`initialize`][] hook.
* `transferList` {Object\[]} [transferrable objects][] to be passed into the
* `transferList` {Object\[]} [transferable objects][] to be passed into the
`initialize` hook.

Register a module that exports [hooks][] that customize Node.js module
Expand Down Expand Up @@ -469,7 +469,7 @@ affect the other thread(s), and message channels must be used to communicate
between the threads.

The `register` method can be used to pass data to an [`initialize`][] hook. The
data passed to the hook may include transferrable objects like ports.
data passed to the hook may include transferable objects like ports.

```mjs
import { register } from 'node:module';
Expand Down Expand Up @@ -567,7 +567,7 @@ the hooks thread when the hooks module is initialized. Initialization happens
when the hooks module is registered via [`register`][].

This hook can receive data from a [`register`][] invocation, including
ports and other transferrable objects. The return value of `initialize` can be a
ports and other transferable objects. The return value of `initialize` can be a
{Promise}, in which case it will be awaited before the main application thread
execution resumes.

Expand Down Expand Up @@ -1118,7 +1118,7 @@ Flush the [module compile cache][] accumulated from modules already loaded
in the current Node.js instance to disk. This returns after all the flushing
file system operations come to an end, no matter they succeed or not. If there
are any errors, this will fail silently, since compile cache misses should not
interfer with the actual operation of the application.
interfere with the actual operation of the application.

### Class: `module.SourceMap`

Expand Down Expand Up @@ -1250,4 +1250,4 @@ returned object contains the following keys:
[prefix-only modules]: modules.md#built-in-modules-with-mandatory-node-prefix
[realm]: https://tc39.es/ecma262/#realm
[source map include directives]: https://sourcemaps.info/spec.html#h.lmz475t4mvbx
[transferrable objects]: worker_threads.md#portpostmessagevalue-transferlist
[transferable objects]: worker_threads.md#portpostmessagevalue-transferlist
4 changes: 2 additions & 2 deletions doc/api/packages.md
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ There is the CommonJS module loader:
`process.dlopen()`.
* It treats all files that lack `.json` or `.node` extensions as JavaScript
text files.
* It can only be used to [load ECMASCript modules from CommonJS modules][] if
* It can only be used to [load ECMAScript modules from CommonJS modules][] if
the module graph is synchronous (that contains no top-level `await`).
When used to load a JavaScript text file that is not an ECMAScript module,
the file will be loaded as a CommonJS module.
Expand Down Expand Up @@ -1423,7 +1423,7 @@ This field defines [subpath imports][] for the current package.
[entry points]: #package-entry-points
[folders as modules]: modules.md#folders-as-modules
[import maps]: https://github.com/WICG/import-maps
[load ECMASCript modules from CommonJS modules]: modules.md#loading-ecmascript-modules-using-require
[load ECMAScript modules from CommonJS modules]: modules.md#loading-ecmascript-modules-using-require
[loader hooks]: esm.md#loaders
[packages folder mapping]: https://github.com/WICG/import-maps#packages-via-trailing-slashes
[self-reference]: #self-referencing-a-package-using-its-name
Expand Down
2 changes: 1 addition & 1 deletion doc/api/stream.md
Original file line number Diff line number Diff line change
Expand Up @@ -2235,7 +2235,7 @@ stopped by having passed a `signal` option and aborting the related
`return`. In either case the stream will be destroyed.

This method is different from listening to the [`'data'`][] event in that it
uses the [`readable`][] event in the underlying machinary and can limit the
uses the [`readable`][] event in the underlying machinery and can limit the
number of concurrent `fn` calls.

```mjs
Expand Down
2 changes: 1 addition & 1 deletion doc/api/test.md
Original file line number Diff line number Diff line change
Expand Up @@ -485,7 +485,7 @@ all tests have completed. If the [`NODE_V8_COVERAGE`][] environment variable is
used to specify a code coverage directory, the generated V8 coverage files are
written to that directory. Node.js core modules and files within
`node_modules/` directories are, by default, not included in the coverage report.
However, they can be explicity included via the [`--test-coverage-include`][] flag. If
However, they can be explicitly included via the [`--test-coverage-include`][] flag. If
coverage is enabled, the coverage report is sent to any [test reporters][] via
the `'test:coverage'` event.

Expand Down
4 changes: 2 additions & 2 deletions doc/api/v8.md
Original file line number Diff line number Diff line change
Expand Up @@ -325,7 +325,7 @@ console.log(queryObjects(B, { format: 'summary' }));

// Note that, when there are child classes inheriting from a constructor,
// the constructor also shows up in the prototype chain of the child
// classes's prototoype, so the child classes's prototoype would also be
// classes's prototype, so the child classes's prototype would also be
// included in the result.
console.log(queryObjects(A)); // 3
// [ "B { foo: 'bar', bar: 'qux' }", 'A {}', "A { foo: 'bar' }" ]
Expand All @@ -349,7 +349,7 @@ console.log(queryObjects(B, { format: 'summary' }));

// Note that, when there are child classes inheriting from a constructor,
// the constructor also shows up in the prototype chain of the child
// classes's prototoype, so the child classes's prototoype would also be
// classes's prototype, so the child classes's prototype would also be
// included in the result.
console.log(queryObjects(A)); // 3
// [ "B { foo: 'bar', bar: 'qux' }", 'A {}', "A { foo: 'bar' }" ]
Expand Down
4 changes: 2 additions & 2 deletions doc/contributing/static-analysis.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ through <https://scan9.scan.coverity.com/reports.htm>.
Any collaborator can ask to be added to the Node.js coverity project
by opening an issue in the [build][] repository titled
`Please add me to coverity`. A member of the build WG with admin access will
verify that the requestor is an existing collaborator as listed in the
verify that the requester is an existing collaborator as listed in the
[collaborators section][] on the nodejs/node project repo. Once validated the
requestor will be added to the coverity project.
requester will be added to the coverity project.

[Node.js coverity project]: https://scan.coverity.com/projects/node-js
[build]: https://github.com/nodejs/build
Expand Down
Loading