@@ -142,22 +142,22 @@ If `cacheDir` is not specified, Node.js will either use the directory specified
142
142
[` NODE_COMPILE_CACHE = dir` ][] environment variable if it's set, or use
143
143
` path .join (os .tmpdir (), ' node-compile-cache' )` otherwise. For general use cases, it's
144
144
recommended to call ` module .enableCompileCache ()` without specifying the ` cacheDir` ,
145
- so that the directory can be overriden by the ` NODE_COMPILE_CACHE ` environment
145
+ so that the directory can be overridden by the ` NODE_COMPILE_CACHE ` environment
146
146
variable when necessary.
147
147
148
148
Since compile cache is supposed to be a quiet optimization that is not required for the
149
149
application to be functional, this method is designed to not throw any exception when the
150
150
compile cache cannot be enabled. Instead, it will return an object containing an error
151
151
message in the ` message` field to aid debugging.
152
- If compile cache is enabled successefully , the ` directory` field in the returned object
152
+ If compile cache is enabled successfully , the ` directory` field in the returned object
153
153
contains the path to the directory where the compile cache is stored. The ` status`
154
154
field in the returned object would be one of the ` module .constants .compileCacheStatus `
155
155
values to indicate the result of the attempt to enable the [module compile cache][].
156
156
157
157
This method only affects the current Node.js instance. To enable it in child worker threads,
158
158
either call this method in child worker threads too, or set the
159
159
` process .env .NODE_COMPILE_CACHE ` value to compile cache directory so the behavior can
160
- be inheritend into the child workers. The directory can be obtained either from the
160
+ be inherited into the child workers. The directory can be obtained either from the
161
161
` directory` field returned by this method, or with [` module .getCompileCacheDir ()` ][].
162
162
163
163
#### Module compile cache
@@ -264,7 +264,7 @@ changes:
264
264
**Default:** ` ' data:' `
265
265
* ` data` {any} Any arbitrary, cloneable JavaScript value to pass into the
266
266
[` initialize` ][] hook.
267
- * ` transferList` {Object\[ ]} [transferrable objects][] to be passed into the
267
+ * ` transferList` {Object\[ ]} [transferable objects][] to be passed into the
268
268
` initialize` hook.
269
269
270
270
Register a module that exports [hooks][] that customize Node.js module
@@ -469,7 +469,7 @@ affect the other thread(s), and message channels must be used to communicate
469
469
between the threads.
470
470
471
471
The ` register` method can be used to pass data to an [` initialize` ][] hook. The
472
- data passed to the hook may include transferrable objects like ports.
472
+ data passed to the hook may include transferable objects like ports.
473
473
474
474
` ` ` mjs
475
475
import { register } from ' node:module' ;
@@ -567,7 +567,7 @@ the hooks thread when the hooks module is initialized. Initialization happens
567
567
when the hooks module is registered via [` register` ][].
568
568
569
569
This hook can receive data from a [` register` ][] invocation, including
570
- ports and other transferrable objects. The return value of ` initialize` can be a
570
+ ports and other transferable objects. The return value of ` initialize` can be a
571
571
{Promise}, in which case it will be awaited before the main application thread
572
572
execution resumes.
573
573
@@ -1118,7 +1118,7 @@ Flush the [module compile cache][] accumulated from modules already loaded
1118
1118
in the current Node.js instance to disk. This returns after all the flushing
1119
1119
file system operations come to an end, no matter they succeed or not. If there
1120
1120
are any errors, this will fail silently, since compile cache misses should not
1121
- interfer with the actual operation of the application.
1121
+ interfere with the actual operation of the application.
1122
1122
1123
1123
### Class: ` module .SourceMap `
1124
1124
@@ -1250,4 +1250,4 @@ returned object contains the following keys:
1250
1250
[prefix-only modules]: modules.md#built-in-modules-with-mandatory-node-prefix
1251
1251
[realm]: https://tc39.es/ecma262/#realm
1252
1252
[source map include directives]: https://sourcemaps.info/spec.html#h.lmz475t4mvbx
1253
- [transferrable objects]: worker_threads.md#portpostmessagevalue-transferlist
1253
+ [transferable objects]: worker_threads.md#portpostmessagevalue-transferlist
0 commit comments