@types/node
Advanced tools
+144
-17
@@ -8,3 +8,11 @@ declare module "node:assert" { | ||
| */ | ||
| function assert(value: unknown, message?: string | Error): asserts value; | ||
| function assert( | ||
| value: unknown, | ||
| message?: Error | assert.AssertMessageFunction, | ||
| ): asserts value; | ||
| function assert( | ||
| value: unknown, | ||
| message: string, | ||
| ...args: unknown[] | ||
| ): asserts value; | ||
| const kOptions: unique symbol; | ||
@@ -181,2 +189,3 @@ namespace assert { | ||
| } | ||
| type AssertMessageFunction = (actual: unknown, expected: unknown) => string; | ||
| type AssertPredicate = RegExp | (new() => object) | ((thrown: unknown) => boolean) | object | Error; | ||
@@ -260,3 +269,11 @@ /** | ||
| */ | ||
| function ok(value: unknown, message?: string | Error): asserts value; | ||
| function ok( | ||
| value: unknown, | ||
| message?: Error | AssertMessageFunction, | ||
| ): asserts value; | ||
| function ok( | ||
| value: unknown, | ||
| message: string, | ||
| ...args: unknown[] | ||
| ): asserts value; | ||
| /** | ||
@@ -295,3 +312,13 @@ * **Strict assertion mode** | ||
| */ | ||
| function equal(actual: unknown, expected: unknown, message?: string | Error): void; | ||
| function equal( | ||
| actual: unknown, | ||
| expected: unknown, | ||
| message?: Error | AssertMessageFunction, | ||
| ): void; | ||
| function equal( | ||
| actual: unknown, | ||
| expected: unknown, | ||
| message: string, | ||
| ...args: unknown[] | ||
| ): void; | ||
| /** | ||
@@ -326,3 +353,13 @@ * **Strict assertion mode** | ||
| */ | ||
| function notEqual(actual: unknown, expected: unknown, message?: string | Error): void; | ||
| function notEqual( | ||
| actual: unknown, | ||
| expected: unknown, | ||
| message?: Error | AssertMessageFunction, | ||
| ): void; | ||
| function notEqual( | ||
| actual: unknown, | ||
| expected: unknown, | ||
| message: string, | ||
| ...args: unknown[] | ||
| ): void; | ||
| /** | ||
@@ -345,3 +382,13 @@ * **Strict assertion mode** | ||
| */ | ||
| function deepEqual(actual: unknown, expected: unknown, message?: string | Error): void; | ||
| function deepEqual( | ||
| actual: unknown, | ||
| expected: unknown, | ||
| message?: Error | AssertMessageFunction, | ||
| ): void; | ||
| function deepEqual( | ||
| actual: unknown, | ||
| expected: unknown, | ||
| message: string, | ||
| ...args: unknown[] | ||
| ): void; | ||
| /** | ||
@@ -396,3 +443,13 @@ * **Strict assertion mode** | ||
| */ | ||
| function notDeepEqual(actual: unknown, expected: unknown, message?: string | Error): void; | ||
| function notDeepEqual( | ||
| actual: unknown, | ||
| expected: unknown, | ||
| message?: Error | AssertMessageFunction, | ||
| ): void; | ||
| function notDeepEqual( | ||
| actual: unknown, | ||
| expected: unknown, | ||
| message: string, | ||
| ...args: unknown[] | ||
| ): void; | ||
| /** | ||
@@ -435,3 +492,13 @@ * Tests strict equality between the `actual` and `expected` parameters as | ||
| */ | ||
| function strictEqual<T>(actual: unknown, expected: T, message?: string | Error): asserts actual is T; | ||
| function strictEqual<T>( | ||
| actual: unknown, | ||
| expected: T, | ||
| message?: Error | AssertMessageFunction, | ||
| ): asserts actual is T; | ||
| function strictEqual<T>( | ||
| actual: unknown, | ||
| expected: T, | ||
| message: string, | ||
| ...args: unknown[] | ||
| ): asserts actual is T; | ||
| /** | ||
@@ -461,3 +528,13 @@ * Tests strict inequality between the `actual` and `expected` parameters as | ||
| */ | ||
| function notStrictEqual(actual: unknown, expected: unknown, message?: string | Error): void; | ||
| function notStrictEqual( | ||
| actual: unknown, | ||
| expected: unknown, | ||
| message?: Error | AssertMessageFunction, | ||
| ): void; | ||
| function notStrictEqual( | ||
| actual: unknown, | ||
| expected: unknown, | ||
| message: string, | ||
| ...args: unknown[] | ||
| ): void; | ||
| /** | ||
@@ -469,3 +546,13 @@ * Tests for deep equality between the `actual` and `expected` parameters. | ||
| */ | ||
| function deepStrictEqual<T>(actual: unknown, expected: T, message?: string | Error): asserts actual is T; | ||
| function deepStrictEqual<T>( | ||
| actual: unknown, | ||
| expected: T, | ||
| message?: Error | AssertMessageFunction, | ||
| ): asserts actual is T; | ||
| function deepStrictEqual<T>( | ||
| actual: unknown, | ||
| expected: T, | ||
| message: string, | ||
| ...args: unknown[] | ||
| ): asserts actual is T; | ||
| /** | ||
@@ -488,3 +575,13 @@ * Tests for deep strict inequality. Opposite of {@link deepStrictEqual}. | ||
| */ | ||
| function notDeepStrictEqual(actual: unknown, expected: unknown, message?: string | Error): void; | ||
| function notDeepStrictEqual( | ||
| actual: unknown, | ||
| expected: unknown, | ||
| message?: Error | AssertMessageFunction, | ||
| ): void; | ||
| function notDeepStrictEqual( | ||
| actual: unknown, | ||
| expected: unknown, | ||
| message: string, | ||
| ...args: unknown[] | ||
| ): void; | ||
| /** | ||
@@ -780,3 +877,3 @@ * Expects the function `fn` to throw an error. | ||
| * If `asyncFn` is a function and it throws an error synchronously, `assert.rejects()` will return a rejected `Promise` with that error. If the | ||
| * function does not return a promise, `assert.rejects()` will return a rejected `Promise` with an [ERR_INVALID_RETURN_VALUE](https://nodejs.org/docs/latest-v25.x/api/errors.html#err_invalid_return_value) | ||
| * function does not return a promise, `assert.rejects()` will return a rejected `Promise` with an [ERR_INVALID_RETURN_VALUE](https://nodejs.org/docs/latest-v26.x/api/errors.html#err_invalid_return_value) | ||
| * error. In both cases the error handler is skipped. | ||
@@ -851,3 +948,3 @@ * | ||
| * the function does not return a promise, `assert.doesNotReject()` will return a | ||
| * rejected `Promise` with an [ERR_INVALID_RETURN_VALUE](https://nodejs.org/docs/latest-v25.x/api/errors.html#err_invalid_return_value) error. In both cases | ||
| * rejected `Promise` with an [ERR_INVALID_RETURN_VALUE](https://nodejs.org/docs/latest-v26.x/api/errors.html#err_invalid_return_value) error. In both cases | ||
| * the error handler is skipped. | ||
@@ -915,6 +1012,16 @@ * | ||
| * undefined, a default error message is assigned. If the `message` parameter is an | ||
| * instance of an [Error](https://nodejs.org/docs/latest-v25.x/api/errors.html#class-error) then it will be thrown instead of the `{@link AssertionError}`. | ||
| * instance of an [Error](https://nodejs.org/docs/latest-v26.x/api/errors.html#class-error) then it will be thrown instead of the `{@link AssertionError}`. | ||
| * @since v13.6.0, v12.16.0 | ||
| */ | ||
| function match(value: string, regExp: RegExp, message?: string | Error): void; | ||
| function match( | ||
| value: string, | ||
| regExp: RegExp, | ||
| message?: Error | AssertMessageFunction, | ||
| ): void; | ||
| function match( | ||
| value: string, | ||
| regExp: RegExp, | ||
| message: string, | ||
| ...args: unknown[] | ||
| ): void; | ||
| /** | ||
@@ -939,6 +1046,16 @@ * Expects the `string` input not to match the regular expression. | ||
| * undefined, a default error message is assigned. If the `message` parameter is an | ||
| * instance of an [Error](https://nodejs.org/docs/latest-v25.x/api/errors.html#class-error) then it will be thrown instead of the `{@link AssertionError}`. | ||
| * instance of an [Error](https://nodejs.org/docs/latest-v26.x/api/errors.html#class-error) then it will be thrown instead of the `{@link AssertionError}`. | ||
| * @since v13.6.0, v12.16.0 | ||
| */ | ||
| function doesNotMatch(value: string, regExp: RegExp, message?: string | Error): void; | ||
| function doesNotMatch( | ||
| value: string, | ||
| regExp: RegExp, | ||
| message?: Error | AssertMessageFunction, | ||
| ): void; | ||
| function doesNotMatch( | ||
| value: string, | ||
| regExp: RegExp, | ||
| message: string, | ||
| ...args: unknown[] | ||
| ): void; | ||
| /** | ||
@@ -955,3 +1072,13 @@ * Tests for partial deep equality between the `actual` and `expected` parameters. | ||
| */ | ||
| function partialDeepStrictEqual(actual: unknown, expected: unknown, message?: string | Error): void; | ||
| function partialDeepStrictEqual( | ||
| actual: unknown, | ||
| expected: unknown, | ||
| message?: Error | AssertMessageFunction, | ||
| ): void; | ||
| function partialDeepStrictEqual( | ||
| actual: unknown, | ||
| expected: unknown, | ||
| message: string, | ||
| ...args: unknown[] | ||
| ): void; | ||
| } | ||
@@ -958,0 +1085,0 @@ namespace assert { |
@@ -6,2 +6,3 @@ declare module "node:assert/strict" { | ||
| AssertionErrorOptions, | ||
| AssertMessageFunction, | ||
| AssertOptions, | ||
@@ -25,3 +26,11 @@ AssertPredicate, | ||
| } from "node:assert"; | ||
| function strict(value: unknown, message?: string | Error): asserts value; | ||
| function strict( | ||
| value: unknown, | ||
| message?: Error | AssertMessageFunction, | ||
| ): asserts value; | ||
| function strict( | ||
| value: unknown, | ||
| message: string, | ||
| ...args: unknown[] | ||
| ): asserts value; | ||
| namespace strict { | ||
@@ -28,0 +37,0 @@ export { |
@@ -31,3 +31,3 @@ declare module "node:async_hooks" { | ||
| * Promise contexts may not get precise `executionAsyncIds` by default. | ||
| * See the section on [promise execution tracking](https://nodejs.org/docs/latest-v25.x/api/async_hooks.html#promise-execution-tracking). | ||
| * See the section on [promise execution tracking](https://nodejs.org/docs/latest-v26.x/api/async_hooks.html#promise-execution-tracking). | ||
| * @since v8.1.0 | ||
@@ -105,3 +105,3 @@ * @return The `asyncId` of the current execution context. Useful to track when something calls. | ||
| * Promise contexts may not get valid `triggerAsyncId`s by default. See | ||
| * the section on [promise execution tracking](https://nodejs.org/docs/latest-v25.x/api/async_hooks.html#promise-execution-tracking). | ||
| * the section on [promise execution tracking](https://nodejs.org/docs/latest-v26.x/api/async_hooks.html#promise-execution-tracking). | ||
| * @return The ID of the resource responsible for calling the callback that is currently being executed. | ||
@@ -112,19 +112,19 @@ */ | ||
| /** | ||
| * The [`init` callback](https://nodejs.org/docs/latest-v25.x/api/async_hooks.html#initasyncid-type-triggerasyncid-resource). | ||
| * The [`init` callback](https://nodejs.org/docs/latest-v26.x/api/async_hooks.html#initasyncid-type-triggerasyncid-resource). | ||
| */ | ||
| init?(asyncId: number, type: string, triggerAsyncId: number, resource: object): void; | ||
| /** | ||
| * The [`before` callback](https://nodejs.org/docs/latest-v25.x/api/async_hooks.html#beforeasyncid). | ||
| * The [`before` callback](https://nodejs.org/docs/latest-v26.x/api/async_hooks.html#beforeasyncid). | ||
| */ | ||
| before?(asyncId: number): void; | ||
| /** | ||
| * The [`after` callback](https://nodejs.org/docs/latest-v25.x/api/async_hooks.html#afterasyncid). | ||
| * The [`after` callback](https://nodejs.org/docs/latest-v26.x/api/async_hooks.html#afterasyncid). | ||
| */ | ||
| after?(asyncId: number): void; | ||
| /** | ||
| * The [`promiseResolve` callback](https://nodejs.org/docs/latest-v25.x/api/async_hooks.html#promiseresolveasyncid). | ||
| * The [`promiseResolve` callback](https://nodejs.org/docs/latest-v26.x/api/async_hooks.html#promiseresolveasyncid). | ||
| */ | ||
| promiseResolve?(asyncId: number): void; | ||
| /** | ||
| * The [`destroy` callback](https://nodejs.org/docs/latest-v25.x/api/async_hooks.html#destroyasyncid). | ||
| * The [`destroy` callback](https://nodejs.org/docs/latest-v26.x/api/async_hooks.html#destroyasyncid). | ||
| */ | ||
@@ -159,3 +159,3 @@ destroy?(asyncId: number): void; | ||
| * specifics of all functions that can be passed to `callbacks` is in the | ||
| * [Hook Callbacks](https://nodejs.org/docs/latest-v25.x/api/async_hooks.html#hook-callbacks) section. | ||
| * [Hook Callbacks](https://nodejs.org/docs/latest-v26.x/api/async_hooks.html#hook-callbacks) section. | ||
| * | ||
@@ -191,3 +191,3 @@ * ```js | ||
| * @since v8.1.0 | ||
| * @param options The [Hook Callbacks](https://nodejs.org/docs/latest-v25.x/api/async_hooks.html#hook-callbacks) to register | ||
| * @param options The [Hook Callbacks](https://nodejs.org/docs/latest-v26.x/api/async_hooks.html#hook-callbacks) to register | ||
| * @returns Instance used for disabling and enabling hooks | ||
@@ -194,0 +194,0 @@ */ |
+17
-21
@@ -407,3 +407,3 @@ declare module "node:child_process" { | ||
| * @since v0.5.9 | ||
| * @param sendHandle `undefined`, or a [`net.Socket`](https://nodejs.org/docs/latest-v25.x/api/net.html#class-netsocket), [`net.Server`](https://nodejs.org/docs/latest-v25.x/api/net.html#class-netserver), or [`dgram.Socket`](https://nodejs.org/docs/latest-v25.x/api/dgram.html#class-dgramsocket) object. | ||
| * @param sendHandle `undefined`, or a [`net.Socket`](https://nodejs.org/docs/latest-v26.x/api/net.html#class-netsocket), [`net.Server`](https://nodejs.org/docs/latest-v26.x/api/net.html#class-netserver), or [`dgram.Socket`](https://nodejs.org/docs/latest-v26.x/api/dgram.html#class-dgramsocket) object. | ||
| * @param options The `options` argument, if present, is an object used to parameterize the sending of certain types of handles. `options` supports the following properties: | ||
@@ -791,12 +791,11 @@ */ | ||
| interface ExecOptionsWithBufferEncoding extends ExecOptions { | ||
| encoding: "buffer" | null; // specify `null`. | ||
| encoding: "buffer" | null; | ||
| } | ||
| // TODO: Just Plain Wrong™ (see also nodejs/node#57392) | ||
| interface ExecException extends Error { | ||
| cmd?: string; | ||
| interface ExecException extends Omit<NodeJS.ErrnoException, "code"> { | ||
| cmd: string; | ||
| code?: number | string; | ||
| killed?: boolean; | ||
| code?: number; | ||
| signal?: NodeJS.Signals; | ||
| stdout?: string; | ||
| stderr?: string; | ||
| stdout?: string | NonSharedBuffer; | ||
| stderr?: string | NonSharedBuffer; | ||
| } | ||
@@ -961,7 +960,2 @@ /** | ||
| interface ExecFileOptionsWithOtherEncoding extends ExecFileOptions {} | ||
| // TODO: execFile exceptions can take many forms... this accurately describes none of them | ||
| type ExecFileException = | ||
| & Omit<ExecException, "code"> | ||
| & Omit<NodeJS.ErrnoException, "code"> | ||
| & { code?: string | number | null }; | ||
| /** | ||
@@ -1034,3 +1028,3 @@ * The `child_process.execFile()` function is similar to {@link exec} except that it does not spawn a shell by default. Rather, the specified | ||
| file: string, | ||
| callback?: (error: ExecFileException | null, stdout: string, stderr: string) => void, | ||
| callback?: (error: ExecException | null, stdout: string, stderr: string) => void, | ||
| ): ChildProcess; | ||
@@ -1040,3 +1034,3 @@ function execFile( | ||
| args: readonly string[] | undefined | null, | ||
| callback?: (error: ExecFileException | null, stdout: string, stderr: string) => void, | ||
| callback?: (error: ExecException | null, stdout: string, stderr: string) => void, | ||
| ): ChildProcess; | ||
@@ -1047,3 +1041,3 @@ // `options` with `"buffer"` or `null` for `encoding` means stdout/stderr are definitely `Buffer`. | ||
| options: ExecFileOptionsWithBufferEncoding, | ||
| callback?: (error: ExecFileException | null, stdout: NonSharedBuffer, stderr: NonSharedBuffer) => void, | ||
| callback?: (error: ExecException | null, stdout: NonSharedBuffer, stderr: NonSharedBuffer) => void, | ||
| ): ChildProcess; | ||
@@ -1054,3 +1048,3 @@ function execFile( | ||
| options: ExecFileOptionsWithBufferEncoding, | ||
| callback?: (error: ExecFileException | null, stdout: NonSharedBuffer, stderr: NonSharedBuffer) => void, | ||
| callback?: (error: ExecException | null, stdout: NonSharedBuffer, stderr: NonSharedBuffer) => void, | ||
| ): ChildProcess; | ||
@@ -1061,3 +1055,3 @@ // `options` with well-known or absent `encoding` means stdout/stderr are definitely `string`. | ||
| options: ExecFileOptionsWithStringEncoding, | ||
| callback?: (error: ExecFileException | null, stdout: string, stderr: string) => void, | ||
| callback?: (error: ExecException | null, stdout: string, stderr: string) => void, | ||
| ): ChildProcess; | ||
@@ -1068,3 +1062,3 @@ function execFile( | ||
| options: ExecFileOptionsWithStringEncoding, | ||
| callback?: (error: ExecFileException | null, stdout: string, stderr: string) => void, | ||
| callback?: (error: ExecException | null, stdout: string, stderr: string) => void, | ||
| ): ChildProcess; | ||
@@ -1077,3 +1071,3 @@ // fallback if nothing else matches. Worst case is always `string | Buffer`. | ||
| | (( | ||
| error: ExecFileException | null, | ||
| error: ExecException | null, | ||
| stdout: string | NonSharedBuffer, | ||
@@ -1091,3 +1085,3 @@ stderr: string | NonSharedBuffer, | ||
| | (( | ||
| error: ExecFileException | null, | ||
| error: ExecException | null, | ||
| stdout: string | NonSharedBuffer, | ||
@@ -1374,2 +1368,4 @@ stderr: string | NonSharedBuffer, | ||
| ): string | NonSharedBuffer; | ||
| /** @deprecated This deprecated alias will be removed in a future version. Use `ExecException` instead. */ | ||
| interface ExecFileException extends ExecException {} | ||
| } | ||
@@ -1376,0 +1372,0 @@ declare module "child_process" { |
+13
-13
@@ -14,6 +14,6 @@ declare module "node:cluster" { | ||
| /** | ||
| * All workers are created using [`child_process.fork()`](https://nodejs.org/docs/latest-v25.x/api/child_process.html#child_processforkmodulepath-args-options), the returned object | ||
| * All workers are created using [`child_process.fork()`](https://nodejs.org/docs/latest-v26.x/api/child_process.html#child_processforkmodulepath-args-options), the returned object | ||
| * from this function is stored as `.process`. In a worker, the global `process` is stored. | ||
| * | ||
| * See: [Child Process module](https://nodejs.org/docs/latest-v25.x/api/child_process.html#child_processforkmodulepath-args-options). | ||
| * See: [Child Process module](https://nodejs.org/docs/latest-v26.x/api/child_process.html#child_processforkmodulepath-args-options). | ||
| * | ||
@@ -29,3 +29,3 @@ * Workers will call `process.exit(0)` if the `'disconnect'` event occurs | ||
| * | ||
| * In the primary, this sends a message to a specific worker. It is identical to [`ChildProcess.send()`](https://nodejs.org/docs/latest-v25.x/api/child_process.html#subprocesssendmessage-sendhandle-options-callback). | ||
| * In the primary, this sends a message to a specific worker. It is identical to [`ChildProcess.send()`](https://nodejs.org/docs/latest-v26.x/api/child_process.html#subprocesssendmessage-sendhandle-options-callback). | ||
| * | ||
@@ -72,3 +72,3 @@ * In a worker, this sends a message to the primary. It is identical to `process.send()`. | ||
| * In a worker, `process.kill()` exists, but it is not this function; | ||
| * it is [`kill()`](https://nodejs.org/docs/latest-v25.x/api/process.html#processkillpid-signal). | ||
| * it is [`kill()`](https://nodejs.org/docs/latest-v26.x/api/process.html#processkillpid-signal). | ||
| * @since v0.9.12 | ||
@@ -251,4 +251,4 @@ * @param [signal='SIGTERM'] Name of the kill signal to send to the worker process. | ||
| * Configures the stdio of forked processes. Because the cluster module relies on IPC to function, this configuration must | ||
| * contain an `'ipc'` entry. When this option is provided, it overrides `silent`. See [`child_prcess.spawn()`](https://nodejs.org/docs/latest-v25.x/api/child_process.html#child_processspawncommand-args-options)'s | ||
| * [`stdio`](https://nodejs.org/docs/latest-v25.x/api/child_process.html#optionsstdio). | ||
| * contain an `'ipc'` entry. When this option is provided, it overrides `silent`. See [`child_prcess.spawn()`](https://nodejs.org/docs/latest-v26.x/api/child_process.html#child_processspawncommand-args-options)'s | ||
| * [`stdio`](https://nodejs.org/docs/latest-v26.x/api/child_process.html#optionsstdio). | ||
| */ | ||
@@ -271,3 +271,3 @@ stdio?: any[] | undefined; | ||
| * Specify the kind of serialization used for sending messages between processes. Possible values are `'json'` and `'advanced'`. | ||
| * See [Advanced serialization for `child_process`](https://nodejs.org/docs/latest-v25.x/api/child_process.html#advanced-serialization) for more details. | ||
| * See [Advanced serialization for `child_process`](https://nodejs.org/docs/latest-v26.x/api/child_process.html#advanced-serialization) for more details. | ||
| * @default false | ||
@@ -341,3 +341,3 @@ */ | ||
| * The scheduling policy, either `cluster.SCHED_RR` for round-robin or `cluster.SCHED_NONE` to leave it to the operating system. This is a | ||
| * global setting and effectively frozen once either the first worker is spawned, or [`.setupPrimary()`](https://nodejs.org/docs/latest-v25.x/api/cluster.html#clustersetupprimarysettings) | ||
| * global setting and effectively frozen once either the first worker is spawned, or [`.setupPrimary()`](https://nodejs.org/docs/latest-v26.x/api/cluster.html#clustersetupprimarysettings) | ||
| * is called, whichever comes first. | ||
@@ -353,4 +353,4 @@ * | ||
| /** | ||
| * After calling [`.setupPrimary()`](https://nodejs.org/docs/latest-v25.x/api/cluster.html#clustersetupprimarysettings) | ||
| * (or [`.fork()`](https://nodejs.org/docs/latest-v25.x/api/cluster.html#clusterforkenv)) this settings object will contain | ||
| * After calling [`.setupPrimary()`](https://nodejs.org/docs/latest-v26.x/api/cluster.html#clustersetupprimarysettings) | ||
| * (or [`.fork()`](https://nodejs.org/docs/latest-v26.x/api/cluster.html#clusterforkenv)) this settings object will contain | ||
| * the settings, including the default values. | ||
@@ -362,3 +362,3 @@ * | ||
| readonly settings: ClusterSettings; | ||
| /** @deprecated since v16.0.0 - use [`.setupPrimary()`](https://nodejs.org/docs/latest-v25.x/api/cluster.html#clustersetupprimarysettings) instead. */ | ||
| /** @deprecated since v16.0.0 - use [`.setupPrimary()`](https://nodejs.org/docs/latest-v26.x/api/cluster.html#clustersetupprimarysettings) instead. */ | ||
| setupMaster(settings?: ClusterSettings): void; | ||
@@ -368,7 +368,7 @@ /** | ||
| * | ||
| * Any settings changes only affect future calls to [`.fork()`](https://nodejs.org/docs/latest-v25.x/api/cluster.html#clusterforkenv) | ||
| * Any settings changes only affect future calls to [`.fork()`](https://nodejs.org/docs/latest-v26.x/api/cluster.html#clusterforkenv) | ||
| * and have no effect on workers that are already running. | ||
| * | ||
| * The only attribute of a worker that cannot be set via `.setupPrimary()` is the `env` passed to | ||
| * [`.fork()`](https://nodejs.org/docs/latest-v25.x/api/cluster.html#clusterforkenv). | ||
| * [`.fork()`](https://nodejs.org/docs/latest-v26.x/api/cluster.html#clusterforkenv). | ||
| * | ||
@@ -375,0 +375,0 @@ * The defaults above apply to the first call only; the defaults for later calls are the current values at the time of |
@@ -22,3 +22,3 @@ declare module "node:console" { | ||
| * Specifies options that are passed along to | ||
| * [`util.inspect()`](https://nodejs.org/docs/latest-v25.x/api/util.html#utilinspectobject-options). | ||
| * [`util.inspect()`](https://nodejs.org/docs/latest-v26.x/api/util.html#utilinspectobject-options). | ||
| */ | ||
@@ -25,0 +25,0 @@ inspectOptions?: InspectOptions | ReadonlyMap<NodeJS.WritableStream, InspectOptions> | undefined; |
@@ -430,8 +430,16 @@ declare module "node:diagnostics_channel" { | ||
| /** | ||
| * Trace a promise-returning function call. This will always produce a `start event` and `end event` around the synchronous portion of the | ||
| * function execution, and will produce an `asyncStart event` and `asyncEnd event` when a promise continuation is reached. It may also | ||
| * produce an `error event` if the given function throws an error or the | ||
| * returned promise rejects. This will run the given function using `channel.runStores(context, ...)` on the `start` channel which ensures all | ||
| * Trace an asynchronous function call which returns a `Promise` or | ||
| * [thenable object](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise#thenables). This will always produce a [`start` event](https://nodejs.org/docs/latest-v26.x/api/diagnostics_channel.html#startevent) and | ||
| * [`end` event](https://nodejs.org/docs/latest-v26.x/api/diagnostics_channel.html#endevent) around the synchronous portion of the function execution, and | ||
| * will produce an [`asyncStart` event](https://nodejs.org/docs/latest-v26.x/api/diagnostics_channel.html#asyncstartevent) and [`asyncEnd` event](https://nodejs.org/docs/latest-v26.x/api/diagnostics_channel.html#asyncendevent) when the | ||
| * returned promise is resolved or rejected. It may also produce an | ||
| * [`error` event](https://nodejs.org/docs/latest-v26.x/api/diagnostics_channel.html#errorevent) if the given function throws an error or the returned promise | ||
| * is rejected. This will run the given function using | ||
| * [`channel.runStores(context, ...)`](https://nodejs.org/docs/latest-v26.x/api/diagnostics_channel.html##channelrunstorescontext-fn-thisarg-args) on the `start` channel which ensures all | ||
| * events should have any bound stores set to match this trace context. | ||
| * | ||
| * If the value returned by `fn` is not a Promise or thenable, then it will be | ||
| * returned with a warning, and no `asyncStart` or `asyncEnd` events will be | ||
| * produced. | ||
| * | ||
| * To ensure only correct trace graphs are formed, events will only be published if subscribers are present prior to starting the trace. Subscriptions | ||
@@ -453,14 +461,17 @@ * which are added after the trace begins will not receive future events from that trace, only future traces will be seen. | ||
| * @experimental | ||
| * @param fn Promise-returning function to wrap a trace around | ||
| * @param fn Function to wrap a trace around | ||
| * @param context Shared object to correlate trace events through | ||
| * @param thisArg The receiver to be used for the function call | ||
| * @param args Optional arguments to pass to the function | ||
| * @return Chained from promise returned by the given function | ||
| * @returns The return value of the given function, or the result of | ||
| * calling `.then(...)` on the return value if the tracing channel has active | ||
| * subscribers. If the return value is not a Promise or thenable, then | ||
| * it is returned as-is and a warning is emitted. | ||
| */ | ||
| tracePromise<ThisArg = any, Args extends any[] = any[], Result = any>( | ||
| fn: (this: ThisArg, ...args: Args) => Promise<Result>, | ||
| tracePromise<ThisArg = any, Args extends any[] = any[], Result extends PromiseLike<unknown> = any>( | ||
| fn: (this: ThisArg, ...args: Args) => Result, | ||
| context?: ContextType, | ||
| thisArg?: ThisArg, | ||
| ...args: Args | ||
| ): Promise<Result>; | ||
| ): Result; | ||
| /** | ||
@@ -467,0 +478,0 @@ * Trace a callback-receiving function call. This will always produce a `start event` and `end event` around the synchronous portion of the |
+14
-14
@@ -27,3 +27,3 @@ declare module "node:dns" { | ||
| /** | ||
| * One or more [supported `getaddrinfo`](https://nodejs.org/docs/latest-v25.x/api/dns.html#supported-getaddrinfo-flags) flags. Multiple flags may be | ||
| * One or more [supported `getaddrinfo`](https://nodejs.org/docs/latest-v26.x/api/dns.html#supported-getaddrinfo-flags) flags. Multiple flags may be | ||
| * passed by bitwise `OR`ing their values. | ||
@@ -41,3 +41,3 @@ */ | ||
| * addresses before IPv4 addresses. Default value is configurable using | ||
| * {@link setDefaultResultOrder} or [`--dns-result-order`](https://nodejs.org/docs/latest-v25.x/api/cli.html#--dns-result-orderorder). | ||
| * {@link setDefaultResultOrder} or [`--dns-result-order`](https://nodejs.org/docs/latest-v26.x/api/cli.html#--dns-result-orderorder). | ||
| * @default `verbatim` (addresses are not reordered) | ||
@@ -91,3 +91,3 @@ * @since v22.1.0 | ||
| * important consequences on the behavior of any Node.js program. Please take some | ||
| * time to consult the [Implementation considerations section](https://nodejs.org/docs/latest-v25.x/api/dns.html#implementation-considerations) | ||
| * time to consult the [Implementation considerations section](https://nodejs.org/docs/latest-v26.x/api/dns.html#implementation-considerations) | ||
| * before using `dns.lookup()`. | ||
@@ -114,3 +114,3 @@ * | ||
| * | ||
| * If this method is invoked as its [util.promisify()](https://nodejs.org/docs/latest-v25.x/api/util.html#utilpromisifyoriginal) ed | ||
| * If this method is invoked as its [util.promisify()](https://nodejs.org/docs/latest-v26.x/api/util.html#utilpromisifyoriginal) ed | ||
| * version, and `all` is not set to `true`, it returns a `Promise` for an `Object` with `address` and `family` properties. | ||
@@ -155,3 +155,3 @@ * @since v0.1.90 | ||
| * | ||
| * On an error, `err` is an [`Error`](https://nodejs.org/docs/latest-v25.x/api/errors.html#class-error) object, | ||
| * On an error, `err` is an [`Error`](https://nodejs.org/docs/latest-v26.x/api/errors.html#class-error) object, | ||
| * where `err.code` is the error code. | ||
@@ -167,3 +167,3 @@ * | ||
| * | ||
| * If this method is invoked as its [util.promisify()](https://nodejs.org/docs/latest-v25.x/api/util.html#utilpromisifyoriginal) ed | ||
| * If this method is invoked as its [util.promisify()](https://nodejs.org/docs/latest-v26.x/api/util.html#utilpromisifyoriginal) ed | ||
| * version, it returns a `Promise` for an `Object` with `hostname` and `service` properties. | ||
@@ -297,3 +297,3 @@ * @since v0.11.14 | ||
| * | ||
| * On error, `err` is an [`Error`](https://nodejs.org/docs/latest-v25.x/api/errors.html#class-error) object, | ||
| * On error, `err` is an [`Error`](https://nodejs.org/docs/latest-v26.x/api/errors.html#class-error) object, | ||
| * where `err.code` is one of the `DNS error codes`. | ||
@@ -677,4 +677,4 @@ * @since v0.1.27 | ||
| * | ||
| * On error, `err` is an [`Error`](https://nodejs.org/docs/latest-v25.x/api/errors.html#class-error) object, where `err.code` is | ||
| * one of the [DNS error codes](https://nodejs.org/docs/latest-v25.x/api/dns.html#error-codes). | ||
| * On error, `err` is an [`Error`](https://nodejs.org/docs/latest-v26.x/api/errors.html#class-error) object, where `err.code` is | ||
| * one of the [DNS error codes](https://nodejs.org/docs/latest-v26.x/api/dns.html#error-codes). | ||
| * @since v0.1.16 | ||
@@ -687,3 +687,3 @@ */ | ||
| /** | ||
| * Get the default value for `order` in {@link lookup} and [`dnsPromises.lookup()`](https://nodejs.org/docs/latest-v25.x/api/dns.html#dnspromiseslookuphostname-options). | ||
| * Get the default value for `order` in {@link lookup} and [`dnsPromises.lookup()`](https://nodejs.org/docs/latest-v26.x/api/dns.html#dnspromiseslookuphostname-options). | ||
| * The value could be: | ||
@@ -743,3 +743,3 @@ * | ||
| /** | ||
| * Set the default value of `order` in {@link lookup} and [`dnsPromises.lookup()`](https://nodejs.org/docs/latest-v25.x/api/dns.html#dnspromiseslookuphostname-options). | ||
| * Set the default value of `order` in {@link lookup} and [`dnsPromises.lookup()`](https://nodejs.org/docs/latest-v26.x/api/dns.html#dnspromiseslookuphostname-options). | ||
| * The value could be: | ||
@@ -752,4 +752,4 @@ * | ||
| * The default is `verbatim` and {@link setDefaultResultOrder} have higher | ||
| * priority than [`--dns-result-order`](https://nodejs.org/docs/latest-v25.x/api/cli.html#--dns-result-orderorder). When using | ||
| * [worker threads](https://nodejs.org/docs/latest-v25.x/api/worker_threads.html), {@link setDefaultResultOrder} from the main | ||
| * priority than [`--dns-result-order`](https://nodejs.org/docs/latest-v26.x/api/cli.html#--dns-result-orderorder). When using | ||
| * [worker threads](https://nodejs.org/docs/latest-v26.x/api/worker_threads.html), {@link setDefaultResultOrder} from the main | ||
| * thread won't affect the default dns orders in workers. | ||
@@ -805,3 +805,3 @@ * @since v16.4.0, v14.18.0 | ||
| * Creating a new resolver uses the default server settings. Setting | ||
| * the servers used for a resolver using [`resolver.setServers()`](https://nodejs.org/docs/latest-v25.x/api/dns.html#dnssetserversservers) does not affect | ||
| * the servers used for a resolver using [`resolver.setServers()`](https://nodejs.org/docs/latest-v26.x/api/dns.html#dnssetserversservers) does not affect | ||
| * other resolvers: | ||
@@ -808,0 +808,0 @@ * |
+3
-3
@@ -35,3 +35,3 @@ declare module "node:events" { | ||
| * It enables | ||
| * [automatic capturing of promise rejection](https://nodejs.org/docs/latest-v25.x/api/events.html#capture-rejections-of-promises). | ||
| * [automatic capturing of promise rejection](https://nodejs.org/docs/latest-v26.x/api/events.html#capture-rejections-of-promises). | ||
| * @default false | ||
@@ -449,3 +449,3 @@ */ | ||
| /** | ||
| * See how to write a custom [rejection handler](https://nodejs.org/docs/latest-v25.x/api/events.html#emittersymbolfornodejsrejectionerr-eventname-args). | ||
| * See how to write a custom [rejection handler](https://nodejs.org/docs/latest-v26.x/api/events.html#emittersymbolfornodejsrejectionerr-eventname-args). | ||
| * @since v13.4.0, v12.16.0 | ||
@@ -862,3 +862,3 @@ */ | ||
| * require manual async tracking. Specifically, all events emitted by instances | ||
| * of `events.EventEmitterAsyncResource` will run within its [async context](https://nodejs.org/docs/latest-v25.x/api/async_context.html). | ||
| * of `events.EventEmitterAsyncResource` will run within its [async context](https://nodejs.org/docs/latest-v26.x/api/async_context.html). | ||
| * | ||
@@ -865,0 +865,0 @@ * ```js |
@@ -259,5 +259,5 @@ declare module "node:fs/promises" { | ||
| * Return the file contents as an async iterable using the | ||
| * [`node:stream/iter`](https://nodejs.org/docs/latest-v25.x/api/stream_iter.html) pull model. Reads are performed in `chunkSize`-byte | ||
| * [`node:stream/iter`](https://nodejs.org/docs/latest-v26.x/api/stream_iter.html) pull model. Reads are performed in `chunkSize`-byte | ||
| * chunks (default 128 KB). If transforms are provided, they are applied | ||
| * via [`stream/iter pull()`](https://nodejs.org/docs/latest-v25.x/api/stream_iter.html#pullsource-transforms-options). | ||
| * via [`stream/iter pull()`](https://nodejs.org/docs/latest-v26.x/api/stream_iter.html#pullsource-transforms-options). | ||
| * | ||
@@ -542,3 +542,3 @@ * The file handle is locked while the iterable is being consumed and unlocked | ||
| /** | ||
| * Return a [`node:stream/iter`](https://nodejs.org/docs/latest-v25.x/api/stream_iter.html) writer backed by this file handle. | ||
| * Return a [`node:stream/iter`](https://nodejs.org/docs/latest-v26.x/api/stream_iter.html) writer backed by this file handle. | ||
| * | ||
@@ -553,3 +553,3 @@ * The writer supports both `Symbol.asyncDispose` and `Symbol.dispose`: | ||
| * The `writeSync()` and `writevSync()` methods enable the try-sync fast path | ||
| * used by [`stream/iter pipeTo()`](https://nodejs.org/docs/latest-v25.x/api/stream_iter.html#pipetosource-transforms-writer). When the reader's chunk size matches the | ||
| * used by [`stream/iter pipeTo()`](https://nodejs.org/docs/latest-v26.x/api/stream_iter.html#pipetosource-transforms-writer). When the reader's chunk size matches the | ||
| * writer's `chunkSize`, all writes in a `pipeTo()` pipeline complete | ||
@@ -556,0 +556,0 @@ * synchronously with zero promise overhead. |
@@ -101,6 +101,6 @@ declare var global: typeof globalThis; | ||
| interface ErrnoException extends Error { | ||
| errno?: number | undefined; | ||
| code?: string | undefined; | ||
| path?: string | undefined; | ||
| syscall?: string | undefined; | ||
| errno?: number; | ||
| code?: string; | ||
| path?: string; | ||
| syscall?: string; | ||
| } | ||
@@ -107,0 +107,0 @@ |
+0
-3
@@ -32,5 +32,2 @@ /** | ||
| // Iterator definitions required for compatibility with TypeScript <5.6: | ||
| /// <reference path="compatibility/iterators.d.ts" /> | ||
| // Definitions for Node.js modules specific to TypeScript 5.7+: | ||
@@ -37,0 +34,0 @@ /// <reference path="globals.typedarray.d.ts" /> |
@@ -37,3 +37,3 @@ declare module "node:inspector" { | ||
| * | ||
| * See the [security warning](https://nodejs.org/docs/latest-v25.x/api/cli.html#warning-binding-inspector-to-a-public-ipport-combination-is-insecure) | ||
| * See the [security warning](https://nodejs.org/docs/latest-v26.x/api/cli.html#warning-binding-inspector-to-a-public-ipport-combination-is-insecure) | ||
| * regarding the `host` parameter usage. | ||
@@ -40,0 +40,0 @@ * @param port Port to listen on for inspector connections. Defaults to what was specified on the CLI. |
+16
-45
@@ -30,3 +30,3 @@ declare module "node:module" { | ||
| * {@link enableCompileCache} to indicate the result of the attempt to enable the | ||
| * [module compile cache](https://nodejs.org/docs/latest-v25.x/api/module.html#module-compile-cache). | ||
| * [module compile cache](https://nodejs.org/docs/latest-v26.x/api/module.html#module-compile-cache). | ||
| * @since v22.8.0 | ||
@@ -100,3 +100,3 @@ */ | ||
| /** | ||
| * Enable [module compile cache](https://nodejs.org/docs/latest-v25.x/api/module.html#module-compile-cache) | ||
| * Enable [module compile cache](https://nodejs.org/docs/latest-v26.x/api/module.html#module-compile-cache) | ||
| * in the current Node.js instance. | ||
@@ -115,3 +115,3 @@ * | ||
| * values to indicate the result of the attempt to enable the | ||
| * [module compile cache](https://nodejs.org/docs/latest-v25.x/api/module.html#module-compile-cache). | ||
| * [module compile cache](https://nodejs.org/docs/latest-v26.x/api/module.html#module-compile-cache). | ||
| * | ||
@@ -128,3 +128,3 @@ * This method only affects the current Node.js instance. To enable it in child worker threads, | ||
| /** | ||
| * Flush the [module compile cache](https://nodejs.org/docs/latest-v25.x/api/module.html#module-compile-cache) | ||
| * Flush the [module compile cache](https://nodejs.org/docs/latest-v26.x/api/module.html#module-compile-cache) | ||
| * accumulated from modules already loaded | ||
@@ -140,3 +140,3 @@ * in the current Node.js instance to disk. This returns after all the flushing | ||
| * @since v22.8.0 | ||
| * @return Path to the [module compile cache](https://nodejs.org/docs/latest-v25.x/api/module.html#module-compile-cache) | ||
| * @return Path to the [module compile cache](https://nodejs.org/docs/latest-v26.x/api/module.html#module-compile-cache) | ||
| * directory if it is enabled, or `undefined` otherwise. | ||
@@ -212,3 +212,3 @@ */ | ||
| /** | ||
| * [Transferable objects](https://nodejs.org/docs/latest-v25.x/api/worker_threads.html#portpostmessagevalue-transferlist) | ||
| * [Transferable objects](https://nodejs.org/docs/latest-v26.x/api/worker_threads.html#portpostmessagevalue-transferlist) | ||
| * to be passed into the `initialize` hook. | ||
@@ -222,6 +222,6 @@ */ | ||
| * resolution and loading behavior. See | ||
| * [Customization hooks](https://nodejs.org/docs/latest-v25.x/api/module.html#customization-hooks). | ||
| * [Customization hooks](https://nodejs.org/docs/latest-v26.x/api/module.html#customization-hooks). | ||
| * | ||
| * This feature requires `--allow-worker` if used with the | ||
| * [Permission Model](https://nodejs.org/docs/latest-v25.x/api/permissions.html#permission-model). | ||
| * [Permission Model](https://nodejs.org/docs/latest-v26.x/api/permissions.html#permission-model). | ||
| * @since v20.6.0, v18.19.0 | ||
@@ -243,3 +243,3 @@ * @deprecated Use `module.registerHooks()` instead. | ||
| /** | ||
| * See [load hook](https://nodejs.org/docs/latest-v25.x/api/module.html#loadurl-context-nextload). | ||
| * See [load hook](https://nodejs.org/docs/latest-v26.x/api/module.html#loadurl-context-nextload). | ||
| * @default undefined | ||
@@ -249,3 +249,3 @@ */ | ||
| /** | ||
| * See [resolve hook](https://nodejs.org/docs/latest-v25.x/api/module.html#resolvespecifier-context-nextresolve). | ||
| * See [resolve hook](https://nodejs.org/docs/latest-v26.x/api/module.html#resolvespecifier-context-nextresolve). | ||
| * @default undefined | ||
@@ -262,3 +262,3 @@ */ | ||
| /** | ||
| * Register [hooks](https://nodejs.org/docs/latest-v25.x/api/module.html#customization-hooks) | ||
| * Register [hooks](https://nodejs.org/docs/latest-v26.x/api/module.html#customization-hooks) | ||
| * that customize Node.js module resolution and loading behavior. | ||
@@ -273,13 +273,6 @@ * @since v22.15.0 | ||
| * * `'strip'` Only strip type annotations without performing the transformation of TypeScript features. | ||
| * * `'transform'` Strip type annotations and transform TypeScript features to JavaScript. | ||
| * @default 'strip' | ||
| */ | ||
| mode?: "strip" | "transform" | undefined; | ||
| mode?: "strip" | undefined; | ||
| /** | ||
| * Only when `mode` is `'transform'`, if `true`, a source map | ||
| * will be generated for the transformed code. | ||
| * @default false | ||
| */ | ||
| sourceMap?: boolean | undefined; | ||
| /** | ||
| * Specifies the source url used in the source map. | ||
@@ -293,9 +286,5 @@ */ | ||
| * with `vm.runInContext()` or `vm.compileFunction()`. | ||
| * | ||
| * By default, it will throw an error if the code contains TypeScript features | ||
| * that require transformation such as `Enums`, | ||
| * see [type-stripping](https://nodejs.org/docs/latest-v25.x/api/typescript.md#type-stripping) for more information. | ||
| * When mode is `'transform'`, it also transforms TypeScript features to JavaScript, | ||
| * see [transform TypeScript features](https://nodejs.org/docs/latest-v25.x/api/typescript.md#typescript-features) for more information. | ||
| * When mode is `'strip'`, source maps are not generated, because locations are preserved. | ||
| * If `sourceMap` is provided, when mode is `'strip'`, an error will be thrown. | ||
| * that require transformation, such as `enum`s. See [type-stripping](https://nodejs.org/docs/latest-v26.x/api/typescript.md#type-stripping) for more information. | ||
| * | ||
@@ -322,20 +311,2 @@ * _WARNING_: The output of this function should not be considered stable across Node.js versions, | ||
| * ``` | ||
| * | ||
| * When `mode` is `'transform'`, the code is transformed to JavaScript: | ||
| * | ||
| * ```js | ||
| * import { stripTypeScriptTypes } from 'node:module'; | ||
| * const code = ` | ||
| * namespace MathUtil { | ||
| * export const add = (a: number, b: number) => a + b; | ||
| * }`; | ||
| * const strippedCode = stripTypeScriptTypes(code, { mode: 'transform', sourceMap: true }); | ||
| * console.log(strippedCode); | ||
| * // Prints: | ||
| * // var MathUtil; | ||
| * // (function(MathUtil) { | ||
| * // MathUtil.add = (a, b)=>a + b; | ||
| * // })(MathUtil || (MathUtil = {})); | ||
| * // # sourceMappingURL=data:application/json;base64, ... | ||
| * ``` | ||
| * @since v22.13.0 | ||
@@ -661,3 +632,3 @@ * @param code The code to strip type annotations from. | ||
| * This does not apply to | ||
| * [native addons](https://nodejs.org/docs/latest-v25.x/api/addons.html), | ||
| * [native addons](https://nodejs.org/docs/latest-v26.x/api/addons.html), | ||
| * for which reloading will result in an error. | ||
@@ -696,3 +667,3 @@ * @since v0.3.0 | ||
| * of | ||
| * [GLOBAL\_FOLDERS](https://nodejs.org/docs/latest-v25.x/api/modules.html#loading-from-the-global-folders) | ||
| * [GLOBAL\_FOLDERS](https://nodejs.org/docs/latest-v26.x/api/modules.html#loading-from-the-global-folders) | ||
| * like `$HOME/.node_modules`, which are | ||
@@ -699,0 +670,0 @@ * always included. Each of these paths is used as a starting point for |
+1
-1
@@ -491,3 +491,3 @@ declare module "node:net" { | ||
| * Optionally overrides all `net.Socket`s' `readableHighWaterMark` and `writableHighWaterMark`. | ||
| * @default See [stream.getDefaultHighWaterMark()](https://nodejs.org/docs/latest-v25.x/api/stream.html#streamgetdefaulthighwatermarkobjectmode). | ||
| * @default See [stream.getDefaultHighWaterMark()](https://nodejs.org/docs/latest-v26.x/api/stream.html#streamgetdefaulthighwatermarkobjectmode). | ||
| * @since v18.17.0, v20.1.0 | ||
@@ -494,0 +494,0 @@ */ |
+2
-2
@@ -245,3 +245,3 @@ declare module "node:os" { | ||
| * | ||
| * Throws a [`SystemError`](https://nodejs.org/docs/latest-v25.x/api/errors.html#class-systemerror) if a user has no `username` or `homedir`. | ||
| * Throws a [`SystemError`](https://nodejs.org/docs/latest-v26.x/api/errors.html#class-systemerror) if a user has no `username` or `homedir`. | ||
| * @since v6.0.0 | ||
@@ -426,3 +426,3 @@ */ | ||
| * | ||
| * The return value is equivalent to [process.arch](https://nodejs.org/docs/latest-v25.x/api/process.html#processarch). | ||
| * The return value is equivalent to [process.arch](https://nodejs.org/docs/latest-v26.x/api/process.html#processarch). | ||
| * @since v0.5.0 | ||
@@ -429,0 +429,0 @@ */ |
| { | ||
| "name": "@types/node", | ||
| "version": "25.9.3", | ||
| "version": "26.0.0", | ||
| "description": "TypeScript definitions for node", | ||
@@ -150,7 +150,7 @@ "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node", | ||
| "dependencies": { | ||
| "undici-types": ">=7.24.0 <7.24.7" | ||
| "undici-types": "~8.3.0" | ||
| }, | ||
| "peerDependencies": {}, | ||
| "typesPublisherContentHash": "b651099f0be23911446e6a283ee816760ef628511df23064b85b949a9ca68cf5", | ||
| "typeScriptVersion": "5.3" | ||
| "typesPublisherContentHash": "b97b21d94288bc153e105a65f4c8fe609dd471f179c5bbd931ba27f959bd0744", | ||
| "typeScriptVersion": "5.6" | ||
| } |
@@ -55,5 +55,2 @@ declare module "node:perf_hooks" { | ||
| } | ||
| // TODO: remove in next major | ||
| /** @deprecated Use `TimerifyOptions` instead. */ | ||
| interface PerformanceTimerifyOptions extends TimerifyOptions {} | ||
| interface PerformanceEventMap { | ||
@@ -463,3 +460,3 @@ "resourcetimingbufferfull": Event; | ||
| * If bootstrapping has not yet finished on the main thread the properties have | ||
| * the value of `0`. The ELU is immediately available on [Worker threads](https://nodejs.org/docs/latest-v25.x/api/worker_threads.html#worker-threads) since | ||
| * the value of `0`. The ELU is immediately available on [Worker threads](https://nodejs.org/docs/latest-v26.x/api/worker_threads.html#worker-threads) since | ||
| * bootstrap happens within the event loop. | ||
@@ -606,7 +603,2 @@ * | ||
| function createHistogram(options?: CreateHistogramOptions): RecordableHistogram; | ||
| // TODO: remove these in a future major | ||
| /** @deprecated Use the canonical `PerformanceMarkOptions` instead. */ | ||
| interface MarkOptions extends PerformanceMarkOptions {} | ||
| /** @deprecated Use the canonical `PerformanceMeasureOptions` instead. */ | ||
| interface MeasureOptions extends PerformanceMeasureOptions {} | ||
| } | ||
@@ -613,0 +605,0 @@ declare module "perf_hooks" { |
+12
-11
@@ -23,3 +23,3 @@ declare module "node:readline" { | ||
| * Instances of the `readline.Interface` class are constructed using the `readline.createInterface()` method. Every instance is associated with a | ||
| * single `input` [Readable](https://nodejs.org/docs/latest-v25.x/api/stream.html#readable-streams) stream and a single `output` [Writable](https://nodejs.org/docs/latest-v25.x/api/stream.html#writable-streams) stream. | ||
| * single `input` [Readable](https://nodejs.org/docs/latest-v26.x/api/stream.html#readable-streams) stream and a single `output` [Writable](https://nodejs.org/docs/latest-v26.x/api/stream.html#writable-streams) stream. | ||
| * The `output` stream is used to print prompts for user input that arrives on, | ||
@@ -36,3 +36,3 @@ * and is read from, the `input` stream. | ||
| * | ||
| * @see https://nodejs.org/dist/latest-v25.x/docs/api/readline.html#class-interfaceconstructor | ||
| * @see https://nodejs.org/dist/latest-v26.x/docs/api/readline.html#class-interfaceconstructor | ||
| */ | ||
@@ -51,3 +51,3 @@ protected constructor( | ||
| * | ||
| * @see https://nodejs.org/dist/latest-v25.x/docs/api/readline.html#class-interfaceconstructor | ||
| * @see https://nodejs.org/dist/latest-v26.x/docs/api/readline.html#class-interfaceconstructor | ||
| */ | ||
@@ -227,3 +227,2 @@ protected constructor(options: ReadLineOptions); | ||
| interface Interface extends InternalEventEmitter<InterfaceEventMap> {} | ||
| type ReadLine = Interface; // type forwarded for backwards compatibility | ||
| type Completer = (line: string) => CompleterResult; | ||
@@ -237,7 +236,7 @@ type AsyncCompleter = ( | ||
| /** | ||
| * The [`Readable`](https://nodejs.org/docs/latest-v25.x/api/stream.html#readable-streams) stream to listen to | ||
| * The [`Readable`](https://nodejs.org/docs/latest-v26.x/api/stream.html#readable-streams) stream to listen to | ||
| */ | ||
| input: NodeJS.ReadableStream; | ||
| /** | ||
| * The [`Writable`](https://nodejs.org/docs/latest-v25.x/api/stream.html#writable-streams) stream to write readline data to. | ||
| * The [`Writable`](https://nodejs.org/docs/latest-v26.x/api/stream.html#writable-streams) stream to write readline data to. | ||
| */ | ||
@@ -287,3 +286,3 @@ output?: NodeJS.WritableStream | undefined; | ||
| * `\r` followed by `\n` will always be considered a single newline | ||
| * (which may be reasonable for [reading files](https://nodejs.org/docs/latest-v25.x/api/readline.html#example-read-file-stream-line-by-line) with `\r\n` line delimiter). | ||
| * (which may be reasonable for [reading files](https://nodejs.org/docs/latest-v26.x/api/readline.html#example-read-file-stream-line-by-line) with `\r\n` line delimiter). | ||
| * @default 100 | ||
@@ -476,3 +475,3 @@ */ | ||
| /** | ||
| * The `readline.clearLine()` method clears current line of given [TTY](https://nodejs.org/docs/latest-v25.x/api/tty.html) stream | ||
| * The `readline.clearLine()` method clears current line of given [TTY](https://nodejs.org/docs/latest-v26.x/api/tty.html) stream | ||
| * in a specified direction identified by `dir`. | ||
@@ -485,3 +484,3 @@ * @since v0.7.7 | ||
| /** | ||
| * The `readline.clearScreenDown()` method clears the given [TTY](https://nodejs.org/docs/latest-v25.x/api/tty.html) stream from | ||
| * The `readline.clearScreenDown()` method clears the given [TTY](https://nodejs.org/docs/latest-v26.x/api/tty.html) stream from | ||
| * the current position of the cursor down. | ||
@@ -495,3 +494,3 @@ * @since v0.7.7 | ||
| * The `readline.cursorTo()` method moves cursor to the specified position in a | ||
| * given [TTY](https://nodejs.org/docs/latest-v25.x/api/tty.html) `stream`. | ||
| * given [TTY](https://nodejs.org/docs/latest-v26.x/api/tty.html) `stream`. | ||
| * @since v0.7.7 | ||
@@ -504,3 +503,3 @@ * @param callback Invoked once the operation completes. | ||
| * The `readline.moveCursor()` method moves the cursor _relative_ to its current | ||
| * position in a given [TTY](https://nodejs.org/docs/latest-v25.x/api/tty.html) `stream`. | ||
| * position in a given [TTY](https://nodejs.org/docs/latest-v26.x/api/tty.html) `stream`. | ||
| * @since v0.7.7 | ||
@@ -511,2 +510,4 @@ * @param callback Invoked once the operation completes. | ||
| function moveCursor(stream: NodeJS.WritableStream, dx: number, dy: number, callback?: () => void): boolean; | ||
| /** @deprecated This alias will be removed in a future version. Use `import { Interface } from 'node:readline'` instead. */ | ||
| type ReadLine = Interface; | ||
| } | ||
@@ -513,0 +514,0 @@ declare module "node:readline" { |
+1
-1
@@ -11,3 +11,3 @@ # Installation | ||
| ### Additional Details | ||
| * Last updated: Wed, 10 Jun 2026 22:15:09 GMT | ||
| * Last updated: Fri, 19 Jun 2026 07:14:38 GMT | ||
| * Dependencies: [undici-types](https://npmjs.com/package/undici-types) | ||
@@ -14,0 +14,0 @@ |
+10
-10
@@ -32,3 +32,3 @@ declare module "node:repl" { | ||
| * error with `repl.Recoverable` to indicate the input was incomplete and prompt for | ||
| * additional lines. See the [custom evaluation functions](https://nodejs.org/dist/latest-v25.x/docs/api/repl.html#custom-evaluation-functions) | ||
| * additional lines. See the [custom evaluation functions](https://nodejs.org/dist/latest-v26.x/docs/api/repl.html#custom-evaluation-functions) | ||
| * section for more details. | ||
@@ -66,3 +66,3 @@ */ | ||
| * | ||
| * @see https://nodejs.org/dist/latest-v25.x/docs/api/repl.html#repl_customizing_repl_output | ||
| * @see https://nodejs.org/dist/latest-v26.x/docs/api/repl.html#repl_customizing_repl_output | ||
| */ | ||
@@ -73,3 +73,3 @@ writer?: REPLWriter | undefined; | ||
| * | ||
| * @see https://nodejs.org/dist/latest-v25.x/docs/api/readline.html#readline_use_of_the_completer_function | ||
| * @see https://nodejs.org/dist/latest-v26.x/docs/api/readline.html#readline_use_of_the_completer_function | ||
| */ | ||
@@ -167,3 +167,3 @@ completer?: Completer | AsyncCompleter | undefined; | ||
| * | ||
| * @see https://nodejs.org/dist/latest-v25.x/docs/api/repl.html#repl_class_replserver | ||
| * @see https://nodejs.org/dist/latest-v26.x/docs/api/repl.html#repl_class_replserver | ||
| */ | ||
@@ -199,3 +199,3 @@ private constructor(); | ||
| * | ||
| * @see https://nodejs.org/dist/latest-v25.x/docs/api/repl.html#repl_commands_and_special_keys | ||
| * @see https://nodejs.org/dist/latest-v26.x/docs/api/repl.html#repl_commands_and_special_keys | ||
| */ | ||
@@ -206,3 +206,3 @@ readonly editorMode: boolean; | ||
| * | ||
| * @see https://nodejs.org/dist/latest-v25.x/docs/api/repl.html#repl_assignment_of_the_underscore_variable | ||
| * @see https://nodejs.org/dist/latest-v26.x/docs/api/repl.html#repl_assignment_of_the_underscore_variable | ||
| */ | ||
@@ -213,3 +213,3 @@ readonly underscoreAssigned: boolean; | ||
| * | ||
| * @see https://nodejs.org/dist/latest-v25.x/docs/api/repl.html#repl_assignment_of_the_underscore_variable | ||
| * @see https://nodejs.org/dist/latest-v26.x/docs/api/repl.html#repl_assignment_of_the_underscore_variable | ||
| */ | ||
@@ -221,3 +221,3 @@ readonly last: any; | ||
| * @since v9.8.0 | ||
| * @see https://nodejs.org/dist/latest-v25.x/docs/api/repl.html#repl_assignment_of_the_underscore_variable | ||
| * @see https://nodejs.org/dist/latest-v26.x/docs/api/repl.html#repl_assignment_of_the_underscore_variable | ||
| */ | ||
@@ -229,3 +229,3 @@ readonly underscoreErrAssigned: boolean; | ||
| * @since v9.8.0 | ||
| * @see https://nodejs.org/dist/latest-v25.x/docs/api/repl.html#repl_assignment_of_the_underscore_variable | ||
| * @see https://nodejs.org/dist/latest-v26.x/docs/api/repl.html#repl_assignment_of_the_underscore_variable | ||
| */ | ||
@@ -420,3 +420,3 @@ readonly lastError: any; | ||
| * | ||
| * @see https://nodejs.org/dist/latest-v25.x/docs/api/repl.html#repl_recoverable_errors | ||
| * @see https://nodejs.org/dist/latest-v26.x/docs/api/repl.html#repl_recoverable_errors | ||
| */ | ||
@@ -423,0 +423,0 @@ class Recoverable extends SyntaxError { |
+1
-1
@@ -339,3 +339,3 @@ declare module "node:sqlite" { | ||
| * invoked. The return value of this function should be a valid SQLite data type: | ||
| * see [Type conversion between JavaScript and SQLite](https://nodejs.org/docs/latest-v25.x/api/sqlite.html#type-conversion-between-javascript-and-sqlite). The result defaults to | ||
| * see [Type conversion between JavaScript and SQLite](https://nodejs.org/docs/latest-v26.x/api/sqlite.html#type-conversion-between-javascript-and-sqlite). The result defaults to | ||
| * `NULL` if the return value is `undefined`. | ||
@@ -342,0 +342,0 @@ */ |
@@ -33,3 +33,3 @@ declare module "node:stream/promises" { | ||
| * | ||
| * The `finished` API also provides a [callback version](https://nodejs.org/docs/latest-v25.x/api/stream.html#streamfinishedstream-options-callback). | ||
| * The `finished` API also provides a [callback version](https://nodejs.org/docs/latest-v26.x/api/stream.html#streamfinishedstream-options-callback). | ||
| * | ||
@@ -133,3 +133,3 @@ * `stream.finished()` leaves dangling event listeners (in particular | ||
| * | ||
| * The `pipeline` API provides [callback version](https://nodejs.org/docs/latest-v25.x/api/stream.html#streampipelinesource-transforms-destination-callback): | ||
| * The `pipeline` API provides [callback version](https://nodejs.org/docs/latest-v26.x/api/stream.html#streampipelinesource-transforms-destination-callback): | ||
| * @since v15.0.0 | ||
@@ -136,0 +136,0 @@ * @returns Fulfills when the pipeline is complete. |
@@ -187,3 +187,3 @@ declare module "node:stream/web" { | ||
| }; | ||
| interface ReadableStreamAsyncIterator<T> extends NodeJS.AsyncIterator<T, NodeJS.BuiltinIteratorReturn, unknown> { | ||
| interface ReadableStreamAsyncIterator<T> extends NodeJS.AsyncIterator<T, BuiltinIteratorReturn, unknown> { | ||
| [Symbol.asyncIterator](): ReadableStreamAsyncIterator<T>; | ||
@@ -190,0 +190,0 @@ } |
@@ -54,3 +54,3 @@ declare module "node:test/reporters" { | ||
| * The `lcov` reporter outputs test coverage when used with the | ||
| * [`--experimental-test-coverage`](https://nodejs.org/docs/latest-v25.x/api/cli.html#--experimental-test-coverage) flag. | ||
| * [`--experimental-test-coverage`](https://nodejs.org/docs/latest-v26.x/api/cli.html#--experimental-test-coverage) flag. | ||
| * @since v22.0.0 | ||
@@ -57,0 +57,0 @@ */ |
+1
-1
@@ -1102,3 +1102,3 @@ declare module "node:tls" { | ||
| * Not all supported ciphers are enabled by default. See | ||
| * [Modifying the default TLS cipher suite](https://nodejs.org/docs/latest-v25.x/api/tls.html#modifying-the-default-tls-cipher-suite). | ||
| * [Modifying the default TLS cipher suite](https://nodejs.org/docs/latest-v26.x/api/tls.html#modifying-the-default-tls-cipher-suite). | ||
| * | ||
@@ -1105,0 +1105,0 @@ * Cipher names that start with `'tls_'` are for TLSv1.3, all the others are for |
@@ -25,3 +25,3 @@ /** | ||
| // NOTE: These definitions support Node.js and TypeScript 5.2 through 5.6. | ||
| // NOTE: These definitions support Node.js and TypeScript 5.6. | ||
@@ -35,5 +35,2 @@ // Reference required TypeScript libraries: | ||
| // Iterator definitions required for compatibility with TypeScript <5.6: | ||
| /// <reference path="../compatibility/iterators.d.ts" /> | ||
| // Definitions for Node.js modules specific to TypeScript <=5.6: | ||
@@ -40,0 +37,0 @@ /// <reference path="./globals.typedarray.d.ts" /> |
@@ -34,5 +34,2 @@ /** | ||
| // Iterator definitions required for compatibility with TypeScript <5.6: | ||
| /// <reference path="../compatibility/iterators.d.ts" /> | ||
| // Definitions for Node.js modules specific to TypeScript 5.7+: | ||
@@ -39,0 +36,0 @@ /// <reference path="../globals.typedarray.d.ts" /> |
+3
-3
@@ -68,3 +68,3 @@ declare module "node:url" { | ||
| * input. CVEs are not issued for `url.parse()` vulnerabilities. Use the | ||
| * [WHATWG URL](https://nodejs.org/docs/latest-v25.x/api/url.html#the-whatwg-url-api) API instead, for example: | ||
| * [WHATWG URL](https://nodejs.org/docs/latest-v26.x/api/url.html#the-whatwg-url-api) API instead, for example: | ||
| * | ||
@@ -92,3 +92,3 @@ * ```js | ||
| * @param parseQueryString If `true`, the `query` property will always | ||
| * be set to an object returned by the [`querystring`](https://nodejs.org/docs/latest-v25.x/api/querystring.html) module's `parse()` | ||
| * be set to an object returned by the [`querystring`](https://nodejs.org/docs/latest-v26.x/api/querystring.html) module's `parse()` | ||
| * method. If `false`, the `query` property on the returned URL object will be an | ||
@@ -551,3 +551,3 @@ * unparsed, undecoded string. **Default:** `false`. | ||
| }; | ||
| interface URLSearchParamsIterator<T> extends NodeJS.Iterator<T, NodeJS.BuiltinIteratorReturn, unknown> { | ||
| interface URLSearchParamsIterator<T> extends NodeJS.Iterator<T, BuiltinIteratorReturn, unknown> { | ||
| [Symbol.iterator](): URLSearchParamsIterator<T>; | ||
@@ -554,0 +554,0 @@ } |
@@ -190,3 +190,3 @@ declare module "node:util/types" { | ||
| * For further information on `napi_create_external`, refer to | ||
| * [`napi_create_external()`](https://nodejs.org/docs/latest-v25.x/api/n-api.html#napi_create_external). | ||
| * [`napi_create_external()`](https://nodejs.org/docs/latest-v26.x/api/n-api.html#napi_create_external). | ||
| * @since v10.0.0 | ||
@@ -193,0 +193,0 @@ */ |
+1
-1
@@ -639,3 +639,3 @@ declare module "node:v8" { | ||
| * The API is a no-op if `--heapsnapshot-near-heap-limit` is already set from the command line or the API is called more than once. | ||
| * `limit` must be a positive integer. See [`--heapsnapshot-near-heap-limit`](https://nodejs.org/docs/latest-v25.x/api/cli.html#--heapsnapshot-near-heap-limitmax_count) for more information. | ||
| * `limit` must be a positive integer. See [`--heapsnapshot-near-heap-limit`](https://nodejs.org/docs/latest-v26.x/api/cli.html#--heapsnapshot-near-heap-limitmax_count) for more information. | ||
| * @since v18.10.0, v16.18.0 | ||
@@ -642,0 +642,0 @@ */ |
+9
-9
@@ -38,3 +38,3 @@ declare module "node:vm" { | ||
| * part of the experimental modules API. We do not recommend using it in a production environment. For detailed information, see | ||
| * [Support of dynamic `import()` in compilation APIs](https://nodejs.org/docs/latest-v25.x/api/vm.html#support-of-dynamic-import-in-compilation-apis). | ||
| * [Support of dynamic `import()` in compilation APIs](https://nodejs.org/docs/latest-v26.x/api/vm.html#support-of-dynamic-import-in-compilation-apis). | ||
| * @experimental | ||
@@ -85,3 +85,3 @@ */ | ||
| * part of the experimental modules API. We do not recommend using it in a production environment. For detailed information, see | ||
| * [Support of dynamic `import()` in compilation APIs](https://nodejs.org/docs/latest-v25.x/api/vm.html#support-of-dynamic-import-in-compilation-apis). | ||
| * [Support of dynamic `import()` in compilation APIs](https://nodejs.org/docs/latest-v26.x/api/vm.html#support-of-dynamic-import-in-compilation-apis). | ||
| * @experimental | ||
@@ -100,3 +100,3 @@ */ | ||
| * part of the experimental modules API. We do not recommend using it in a production environment. For detailed information, see | ||
| * [Support of dynamic `import()` in compilation APIs](https://nodejs.org/docs/latest-v25.x/api/vm.html#support-of-dynamic-import-in-compilation-apis). | ||
| * [Support of dynamic `import()` in compilation APIs](https://nodejs.org/docs/latest-v26.x/api/vm.html#support-of-dynamic-import-in-compilation-apis). | ||
| * @experimental | ||
@@ -121,3 +121,3 @@ */ | ||
| * part of the experimental modules API. We do not recommend using it in a production environment. For detailed information, see | ||
| * [Support of dynamic `import()` in compilation APIs](https://nodejs.org/docs/latest-v25.x/api/vm.html#support-of-dynamic-import-in-compilation-apis). | ||
| * [Support of dynamic `import()` in compilation APIs](https://nodejs.org/docs/latest-v26.x/api/vm.html#support-of-dynamic-import-in-compilation-apis). | ||
| * @experimental | ||
@@ -166,3 +166,3 @@ */ | ||
| * part of the experimental modules API. We do not recommend using it in a production environment. For detailed information, see | ||
| * [Support of dynamic `import()` in compilation APIs](https://nodejs.org/docs/latest-v25.x/api/vm.html#support-of-dynamic-import-in-compilation-apis). | ||
| * [Support of dynamic `import()` in compilation APIs](https://nodejs.org/docs/latest-v26.x/api/vm.html#support-of-dynamic-import-in-compilation-apis). | ||
| * @experimental | ||
@@ -371,5 +371,5 @@ */ | ||
| * If the given `contextObject` is an object, the `vm.createContext()` method will | ||
| * [prepare that object](https://nodejs.org/docs/latest-v25.x/api/vm.html#what-does-it-mean-to-contextify-an-object) | ||
| * [prepare that object](https://nodejs.org/docs/latest-v26.x/api/vm.html#what-does-it-mean-to-contextify-an-object) | ||
| * and return a reference to it so that it can be used in calls to {@link runInContext} or | ||
| * [`script.runInContext()`](https://nodejs.org/docs/latest-v25.x/api/vm.html#scriptrunincontextcontextifiedobject-options). | ||
| * [`script.runInContext()`](https://nodejs.org/docs/latest-v26.x/api/vm.html#scriptrunincontextcontextifiedobject-options). | ||
| * Inside such scripts, the global object will be wrapped by the `contextObject`, retaining all of its | ||
@@ -846,3 +846,3 @@ * existing properties but also having the built-in objects and functions any standard | ||
| * part of the experimental modules API. We do not recommend using it in a production environment. For detailed information, see | ||
| * [Support of dynamic `import()` in compilation APIs](https://nodejs.org/docs/latest-v25.x/api/vm.html#support-of-dynamic-import-in-compilation-apis). | ||
| * [Support of dynamic `import()` in compilation APIs](https://nodejs.org/docs/latest-v26.x/api/vm.html#support-of-dynamic-import-in-compilation-apis). | ||
| * @experimental | ||
@@ -1122,3 +1122,3 @@ */ | ||
| * | ||
| * For detailed information, see [Support of dynamic `import()` in compilation APIs](https://nodejs.org/docs/latest-v25.x/api/vm.html#support-of-dynamic-import-in-compilation-apis). | ||
| * For detailed information, see [Support of dynamic `import()` in compilation APIs](https://nodejs.org/docs/latest-v26.x/api/vm.html#support-of-dynamic-import-in-compilation-apis). | ||
| * @since v21.7.0, v20.12.0 | ||
@@ -1125,0 +1125,0 @@ */ |
@@ -68,2 +68,17 @@ export {}; | ||
| }; | ||
| // Not conditional, as this is not yet exposed by the DOM lib generator. | ||
| interface QuotaExceededError extends DOMException { | ||
| readonly quota: number | null; | ||
| readonly requested: number | null; | ||
| } | ||
| var QuotaExceededError: { | ||
| prototype: QuotaExceededError; | ||
| new(message?: string, options?: QuotaExceededErrorOptions): QuotaExceededError; | ||
| }; | ||
| interface QuotaExceededErrorOptions { | ||
| quota?: number; | ||
| requested?: number; | ||
| } | ||
| } |
@@ -25,5 +25,2 @@ declare module "node:worker_threads" { | ||
| interface WorkerPerformance extends Pick<Performance, "eventLoopUtilization"> {} | ||
| /** @deprecated Use `import { Transferable } from "node:worker_threads"` instead. */ | ||
| // TODO: remove in a future major @types/node version. | ||
| type TransferListItem = Transferable; | ||
| interface WorkerOptions { | ||
@@ -344,3 +341,3 @@ /** | ||
| * Mark an object as not transferable. If `object` occurs in the transfer list of | ||
| * a [`port.postMessage()`](https://nodejs.org/docs/latest-v25.x/api/worker_threads.html#portpostmessagevalue-transferlist) call, an error is thrown. This is a no-op if | ||
| * a [`port.postMessage()`](https://nodejs.org/docs/latest-v26.x/api/worker_threads.html#portpostmessagevalue-transferlist) call, an error is thrown. This is a no-op if | ||
| * `object` is a primitive value. | ||
@@ -351,3 +348,3 @@ * | ||
| * For example, Node.js marks the `ArrayBuffer`s it uses for its | ||
| * [`Buffer` pool](https://nodejs.org/docs/latest-v25.x/api/buffer.html#static-method-bufferallocunsafesize) with this. | ||
| * [`Buffer` pool](https://nodejs.org/docs/latest-v26.x/api/buffer.html#static-method-bufferallocunsafesize) with this. | ||
| * `ArrayBuffer.prototype.transfer()` is disallowed on such array buffer | ||
@@ -354,0 +351,0 @@ * instances. |
+3
-3
@@ -58,3 +58,3 @@ declare module "node:zlib" { | ||
| /** | ||
| * Limits output size when using [convenience methods](https://nodejs.org/docs/latest-v25.x/api/zlib.html#convenience-methods). | ||
| * Limits output size when using [convenience methods](https://nodejs.org/docs/latest-v26.x/api/zlib.html#convenience-methods). | ||
| * @default buffer.kMaxLength | ||
@@ -83,3 +83,3 @@ */ | ||
| * Key-value object containing indexed | ||
| * [Zstd parameters](https://nodejs.org/docs/latest-v25.x/api/zlib.html#zstd-constants). | ||
| * [Zstd parameters](https://nodejs.org/docs/latest-v26.x/api/zlib.html#zstd-constants). | ||
| */ | ||
@@ -89,3 +89,3 @@ params?: { [key: number]: number | boolean } | undefined; | ||
| * Limits output size when using | ||
| * [convenience methods](https://nodejs.org/docs/latest-v25.x/api/zlib.html#convenience-methods). | ||
| * [convenience methods](https://nodejs.org/docs/latest-v26.x/api/zlib.html#convenience-methods). | ||
| * @default buffer.kMaxLength | ||
@@ -92,0 +92,0 @@ */ |
| // Backwards-compatible iterator interfaces, augmented with iterator helper methods by lib.esnext.iterator in TypeScript 5.6. | ||
| // The IterableIterator interface does not contain these methods, which creates assignability issues in places where IteratorObjects | ||
| // are expected (eg. DOM-compatible APIs) if lib.esnext.iterator is loaded. | ||
| // Also ensures that iterators returned by the Node API, which inherit from Iterator.prototype, correctly expose the iterator helper methods | ||
| // if lib.esnext.iterator is loaded. | ||
| // TODO: remove once this package no longer supports TS 5.5, and replace NodeJS.BuiltinIteratorReturn with BuiltinIteratorReturn. | ||
| // Placeholders for TS <5.6 | ||
| interface IteratorObject<T, TReturn, TNext> {} | ||
| interface AsyncIteratorObject<T, TReturn, TNext> {} | ||
| declare namespace NodeJS { | ||
| // Populate iterator methods for TS <5.6 | ||
| interface Iterator<T, TReturn, TNext> extends globalThis.Iterator<T, TReturn, TNext> {} | ||
| interface AsyncIterator<T, TReturn, TNext> extends globalThis.AsyncIterator<T, TReturn, TNext> {} | ||
| // Polyfill for TS 5.6's instrinsic BuiltinIteratorReturn type, required for DOM-compatible iterators | ||
| type BuiltinIteratorReturn = ReturnType<any[][typeof Symbol.iterator]> extends | ||
| globalThis.Iterator<any, infer TReturn> ? TReturn | ||
| : any; | ||
| } |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
2386939
-0.22%90
-1.1%53080
-0.1%+ Added
- Removed
Updated