@types/node 22.15.21 → 22.15.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (4) hide show
  1. node/README.md +1 -1
  2. node/module.d.ts +18 -2
  3. node/package.json +2 -2
  4. node/stream.d.ts +6 -0
node/README.md CHANGED
@@ -8,7 +8,7 @@ This package contains type definitions for node (https://nodejs.org/).
8
8
  Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Tue, 20 May 2025 23:02:19 GMT
11
+ * Last updated: Tue, 27 May 2025 18:40:40 GMT
12
12
  * Dependencies: [undici-types](https://npmjs.com/package/undici-types)
13
13
 
14
14
  # Credits
node/module.d.ts CHANGED
@@ -225,12 +225,12 @@ declare module "module" {
225
225
  * See [load hook](https://nodejs.org/docs/latest-v22.x/api/module.html#loadurl-context-nextload).
226
226
  * @default undefined
227
227
  */
228
- load?: LoadHook | undefined;
228
+ load?: LoadHookSync | undefined;
229
229
  /**
230
230
  * See [resolve hook](https://nodejs.org/docs/latest-v22.x/api/module.html#resolvespecifier-context-nextresolve).
231
231
  * @default undefined
232
232
  */
233
- resolve?: ResolveHook | undefined;
233
+ resolve?: ResolveHookSync | undefined;
234
234
  }
235
235
  interface ModuleHooks {
236
236
  /**
@@ -429,6 +429,14 @@ declare module "module" {
429
429
  context?: Partial<ResolveHookContext>,
430
430
  ) => ResolveFnOutput | Promise<ResolveFnOutput>,
431
431
  ) => ResolveFnOutput | Promise<ResolveFnOutput>;
432
+ type ResolveHookSync = (
433
+ specifier: string,
434
+ context: ResolveHookContext,
435
+ nextResolve: (
436
+ specifier: string,
437
+ context?: Partial<ResolveHookContext>,
438
+ ) => ResolveFnOutput,
439
+ ) => ResolveFnOutput;
432
440
  interface LoadHookContext {
433
441
  /**
434
442
  * Export conditions of the relevant `package.json`
@@ -468,6 +476,14 @@ declare module "module" {
468
476
  context?: Partial<LoadHookContext>,
469
477
  ) => LoadFnOutput | Promise<LoadFnOutput>,
470
478
  ) => LoadFnOutput | Promise<LoadFnOutput>;
479
+ type LoadHookSync = (
480
+ url: string,
481
+ context: LoadHookContext,
482
+ nextLoad: (
483
+ url: string,
484
+ context?: Partial<LoadHookContext>,
485
+ ) => LoadFnOutput,
486
+ ) => LoadFnOutput;
471
487
  /**
472
488
  * `path` is the resolved path for the file for which a corresponding source map
473
489
  * should be fetched.
node/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "22.15.21",
3
+ "version": "22.15.23",
4
4
  "description": "TypeScript definitions for node",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
6
6
  "license": "MIT",
@@ -220,6 +220,6 @@
220
220
  "undici-types": "~6.21.0"
221
221
  },
222
222
  "peerDependencies": {},
223
- "typesPublisherContentHash": "5d2f879a002d15b5c339ca2ceae4757f171fe11f54ad330e4325efc50af262a7",
223
+ "typesPublisherContentHash": "3844c0b84003a1c9382712245a57b4124212f8132db577606add964efd038ea4",
224
224
  "typeScriptVersion": "5.1"
225
225
  }
node/stream.d.ts CHANGED
@@ -737,6 +737,12 @@ declare module "stream" {
737
737
  * @since v11.4.0
738
738
  */
739
739
  readonly writable: boolean;
740
+ /**
741
+ * Returns whether the stream was destroyed or errored before emitting `'finish'`.
742
+ * @since v18.0.0, v16.17.0
743
+ * @experimental
744
+ */
745
+ readonly writableAborted: boolean;
740
746
  /**
741
747
  * Is `true` after `writable.end()` has been called. This property
742
748
  * does not indicate whether the data has been flushed, for this use `writable.writableFinished` instead.