@types/node 20.9.2 → 20.9.4

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.
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: Sat, 18 Nov 2023 20:07:14 GMT
11
+ * Last updated: Wed, 22 Nov 2023 00:24:48 GMT
12
12
  * Dependencies: [undici-types](https://npmjs.com/package/undici-types)
13
13
 
14
14
  # Credits
node/assert.d.ts CHANGED
@@ -45,7 +45,7 @@ declare module "assert" {
45
45
  /** The `operator` property on the error instance. */
46
46
  operator?: string | undefined;
47
47
  /** If provided, the generated stack trace omits frames before this function. */
48
- // tslint:disable-next-line:ban-types
48
+ // eslint-disable-next-line @typescript-eslint/ban-types
49
49
  stackStartFn?: Function | undefined;
50
50
  });
51
51
  }
@@ -228,7 +228,7 @@ declare module "assert" {
228
228
  expected: unknown,
229
229
  message?: string | Error,
230
230
  operator?: string,
231
- // tslint:disable-next-line:ban-types
231
+ // eslint-disable-next-line @typescript-eslint/ban-types
232
232
  stackStartFn?: Function,
233
233
  ): never;
234
234
  /**
node/buffer.d.ts CHANGED
@@ -289,7 +289,7 @@ declare module "buffer" {
289
289
  * @param array The octets to store.
290
290
  * @deprecated since v10.0.0 - Use `Buffer.from(array)` instead.
291
291
  */
292
- new(array: ReadonlyArray<any>): Buffer;
292
+ new(array: readonly any[]): Buffer;
293
293
  /**
294
294
  * Copies the passed {buffer} data onto a new {Buffer} instance.
295
295
  *
@@ -327,8 +327,8 @@ declare module "buffer" {
327
327
  * Creates a new Buffer using the passed {data}
328
328
  * @param data data to create a new Buffer
329
329
  */
330
- from(data: Uint8Array | ReadonlyArray<number>): Buffer;
331
- from(data: WithImplicitCoercion<Uint8Array | ReadonlyArray<number> | string>): Buffer;
330
+ from(data: Uint8Array | readonly number[]): Buffer;
331
+ from(data: WithImplicitCoercion<Uint8Array | readonly number[] | string>): Buffer;
332
332
  /**
333
333
  * Creates a new Buffer containing the given JavaScript string {str}.
334
334
  * If provided, the {encoding} parameter identifies the character encoding.
@@ -456,7 +456,7 @@ declare module "buffer" {
456
456
  * @param list List of `Buffer` or {@link Uint8Array} instances to concatenate.
457
457
  * @param totalLength Total length of the `Buffer` instances in `list` when concatenated.
458
458
  */
459
- concat(list: ReadonlyArray<Uint8Array>, totalLength?: number): Buffer;
459
+ concat(list: readonly Uint8Array[], totalLength?: number): Buffer;
460
460
  /**
461
461
  * Copies the underlying memory of `view` into a new `Buffer`.
462
462
  *
node/child_process.d.ts CHANGED
@@ -833,50 +833,50 @@ declare module "child_process" {
833
833
  // overloads of spawn with 'args'
834
834
  function spawn(
835
835
  command: string,
836
- args?: ReadonlyArray<string>,
836
+ args?: readonly string[],
837
837
  options?: SpawnOptionsWithoutStdio,
838
838
  ): ChildProcessWithoutNullStreams;
839
839
  function spawn(
840
840
  command: string,
841
- args: ReadonlyArray<string>,
841
+ args: readonly string[],
842
842
  options: SpawnOptionsWithStdioTuple<StdioPipe, StdioPipe, StdioPipe>,
843
843
  ): ChildProcessByStdio<Writable, Readable, Readable>;
844
844
  function spawn(
845
845
  command: string,
846
- args: ReadonlyArray<string>,
846
+ args: readonly string[],
847
847
  options: SpawnOptionsWithStdioTuple<StdioPipe, StdioPipe, StdioNull>,
848
848
  ): ChildProcessByStdio<Writable, Readable, null>;
849
849
  function spawn(
850
850
  command: string,
851
- args: ReadonlyArray<string>,
851
+ args: readonly string[],
852
852
  options: SpawnOptionsWithStdioTuple<StdioPipe, StdioNull, StdioPipe>,
853
853
  ): ChildProcessByStdio<Writable, null, Readable>;
854
854
  function spawn(
855
855
  command: string,
856
- args: ReadonlyArray<string>,
856
+ args: readonly string[],
857
857
  options: SpawnOptionsWithStdioTuple<StdioNull, StdioPipe, StdioPipe>,
858
858
  ): ChildProcessByStdio<null, Readable, Readable>;
859
859
  function spawn(
860
860
  command: string,
861
- args: ReadonlyArray<string>,
861
+ args: readonly string[],
862
862
  options: SpawnOptionsWithStdioTuple<StdioPipe, StdioNull, StdioNull>,
863
863
  ): ChildProcessByStdio<Writable, null, null>;
864
864
  function spawn(
865
865
  command: string,
866
- args: ReadonlyArray<string>,
866
+ args: readonly string[],
867
867
  options: SpawnOptionsWithStdioTuple<StdioNull, StdioPipe, StdioNull>,
868
868
  ): ChildProcessByStdio<null, Readable, null>;
869
869
  function spawn(
870
870
  command: string,
871
- args: ReadonlyArray<string>,
871
+ args: readonly string[],
872
872
  options: SpawnOptionsWithStdioTuple<StdioNull, StdioNull, StdioPipe>,
873
873
  ): ChildProcessByStdio<null, null, Readable>;
874
874
  function spawn(
875
875
  command: string,
876
- args: ReadonlyArray<string>,
876
+ args: readonly string[],
877
877
  options: SpawnOptionsWithStdioTuple<StdioNull, StdioNull, StdioNull>,
878
878
  ): ChildProcessByStdio<null, null, null>;
879
- function spawn(command: string, args: ReadonlyArray<string>, options: SpawnOptions): ChildProcess;
879
+ function spawn(command: string, args: readonly string[], options: SpawnOptions): ChildProcess;
880
880
  interface ExecOptions extends CommonOptions {
881
881
  shell?: string | undefined;
882
882
  signal?: AbortSignal | undefined;
@@ -1150,10 +1150,10 @@ declare module "child_process" {
1150
1150
  file: string,
1151
1151
  options: (ObjectEncodingOptions & ExecFileOptions) | undefined | null,
1152
1152
  ): ChildProcess;
1153
- function execFile(file: string, args?: ReadonlyArray<string> | null): ChildProcess;
1153
+ function execFile(file: string, args?: readonly string[] | null): ChildProcess;
1154
1154
  function execFile(
1155
1155
  file: string,
1156
- args: ReadonlyArray<string> | undefined | null,
1156
+ args: readonly string[] | undefined | null,
1157
1157
  options: (ObjectEncodingOptions & ExecFileOptions) | undefined | null,
1158
1158
  ): ChildProcess;
1159
1159
  // no `options` definitely means stdout/stderr are `string`.
@@ -1163,7 +1163,7 @@ declare module "child_process" {
1163
1163
  ): ChildProcess;
1164
1164
  function execFile(
1165
1165
  file: string,
1166
- args: ReadonlyArray<string> | undefined | null,
1166
+ args: readonly string[] | undefined | null,
1167
1167
  callback: (error: ExecFileException | null, stdout: string, stderr: string) => void,
1168
1168
  ): ChildProcess;
1169
1169
  // `options` with `"buffer"` or `null` for `encoding` means stdout/stderr are definitely `Buffer`.
@@ -1174,7 +1174,7 @@ declare module "child_process" {
1174
1174
  ): ChildProcess;
1175
1175
  function execFile(
1176
1176
  file: string,
1177
- args: ReadonlyArray<string> | undefined | null,
1177
+ args: readonly string[] | undefined | null,
1178
1178
  options: ExecFileOptionsWithBufferEncoding,
1179
1179
  callback: (error: ExecFileException | null, stdout: Buffer, stderr: Buffer) => void,
1180
1180
  ): ChildProcess;
@@ -1186,7 +1186,7 @@ declare module "child_process" {
1186
1186
  ): ChildProcess;
1187
1187
  function execFile(
1188
1188
  file: string,
1189
- args: ReadonlyArray<string> | undefined | null,
1189
+ args: readonly string[] | undefined | null,
1190
1190
  options: ExecFileOptionsWithStringEncoding,
1191
1191
  callback: (error: ExecFileException | null, stdout: string, stderr: string) => void,
1192
1192
  ): ChildProcess;
@@ -1199,7 +1199,7 @@ declare module "child_process" {
1199
1199
  ): ChildProcess;
1200
1200
  function execFile(
1201
1201
  file: string,
1202
- args: ReadonlyArray<string> | undefined | null,
1202
+ args: readonly string[] | undefined | null,
1203
1203
  options: ExecFileOptionsWithOtherEncoding,
1204
1204
  callback: (error: ExecFileException | null, stdout: string | Buffer, stderr: string | Buffer) => void,
1205
1205
  ): ChildProcess;
@@ -1211,7 +1211,7 @@ declare module "child_process" {
1211
1211
  ): ChildProcess;
1212
1212
  function execFile(
1213
1213
  file: string,
1214
- args: ReadonlyArray<string> | undefined | null,
1214
+ args: readonly string[] | undefined | null,
1215
1215
  options: ExecFileOptions,
1216
1216
  callback: (error: ExecFileException | null, stdout: string, stderr: string) => void,
1217
1217
  ): ChildProcess;
@@ -1226,7 +1226,7 @@ declare module "child_process" {
1226
1226
  ): ChildProcess;
1227
1227
  function execFile(
1228
1228
  file: string,
1229
- args: ReadonlyArray<string> | undefined | null,
1229
+ args: readonly string[] | undefined | null,
1230
1230
  options: (ObjectEncodingOptions & ExecFileOptions) | undefined | null,
1231
1231
  callback:
1232
1232
  | ((error: ExecFileException | null, stdout: string | Buffer, stderr: string | Buffer) => void)
@@ -1240,7 +1240,7 @@ declare module "child_process" {
1240
1240
  }>;
1241
1241
  function __promisify__(
1242
1242
  file: string,
1243
- args: ReadonlyArray<string> | undefined | null,
1243
+ args: readonly string[] | undefined | null,
1244
1244
  ): PromiseWithChild<{
1245
1245
  stdout: string;
1246
1246
  stderr: string;
@@ -1254,7 +1254,7 @@ declare module "child_process" {
1254
1254
  }>;
1255
1255
  function __promisify__(
1256
1256
  file: string,
1257
- args: ReadonlyArray<string> | undefined | null,
1257
+ args: readonly string[] | undefined | null,
1258
1258
  options: ExecFileOptionsWithBufferEncoding,
1259
1259
  ): PromiseWithChild<{
1260
1260
  stdout: Buffer;
@@ -1269,7 +1269,7 @@ declare module "child_process" {
1269
1269
  }>;
1270
1270
  function __promisify__(
1271
1271
  file: string,
1272
- args: ReadonlyArray<string> | undefined | null,
1272
+ args: readonly string[] | undefined | null,
1273
1273
  options: ExecFileOptionsWithStringEncoding,
1274
1274
  ): PromiseWithChild<{
1275
1275
  stdout: string;
@@ -1284,7 +1284,7 @@ declare module "child_process" {
1284
1284
  }>;
1285
1285
  function __promisify__(
1286
1286
  file: string,
1287
- args: ReadonlyArray<string> | undefined | null,
1287
+ args: readonly string[] | undefined | null,
1288
1288
  options: ExecFileOptionsWithOtherEncoding,
1289
1289
  ): PromiseWithChild<{
1290
1290
  stdout: string | Buffer;
@@ -1299,7 +1299,7 @@ declare module "child_process" {
1299
1299
  }>;
1300
1300
  function __promisify__(
1301
1301
  file: string,
1302
- args: ReadonlyArray<string> | undefined | null,
1302
+ args: readonly string[] | undefined | null,
1303
1303
  options: ExecFileOptions,
1304
1304
  ): PromiseWithChild<{
1305
1305
  stdout: string;
@@ -1314,7 +1314,7 @@ declare module "child_process" {
1314
1314
  }>;
1315
1315
  function __promisify__(
1316
1316
  file: string,
1317
- args: ReadonlyArray<string> | undefined | null,
1317
+ args: readonly string[] | undefined | null,
1318
1318
  options: (ObjectEncodingOptions & ExecFileOptions) | undefined | null,
1319
1319
  ): PromiseWithChild<{
1320
1320
  stdout: string | Buffer;
@@ -1388,7 +1388,7 @@ declare module "child_process" {
1388
1388
  * @param args List of string arguments.
1389
1389
  */
1390
1390
  function fork(modulePath: string, options?: ForkOptions): ChildProcess;
1391
- function fork(modulePath: string, args?: ReadonlyArray<string>, options?: ForkOptions): ChildProcess;
1391
+ function fork(modulePath: string, args?: readonly string[], options?: ForkOptions): ChildProcess;
1392
1392
  interface SpawnSyncOptions extends CommonSpawnOptions {
1393
1393
  input?: string | NodeJS.ArrayBufferView | undefined;
1394
1394
  maxBuffer?: number | undefined;
@@ -1428,20 +1428,20 @@ declare module "child_process" {
1428
1428
  function spawnSync(command: string, options: SpawnSyncOptionsWithStringEncoding): SpawnSyncReturns<string>;
1429
1429
  function spawnSync(command: string, options: SpawnSyncOptionsWithBufferEncoding): SpawnSyncReturns<Buffer>;
1430
1430
  function spawnSync(command: string, options?: SpawnSyncOptions): SpawnSyncReturns<string | Buffer>;
1431
- function spawnSync(command: string, args: ReadonlyArray<string>): SpawnSyncReturns<Buffer>;
1431
+ function spawnSync(command: string, args: readonly string[]): SpawnSyncReturns<Buffer>;
1432
1432
  function spawnSync(
1433
1433
  command: string,
1434
- args: ReadonlyArray<string>,
1434
+ args: readonly string[],
1435
1435
  options: SpawnSyncOptionsWithStringEncoding,
1436
1436
  ): SpawnSyncReturns<string>;
1437
1437
  function spawnSync(
1438
1438
  command: string,
1439
- args: ReadonlyArray<string>,
1439
+ args: readonly string[],
1440
1440
  options: SpawnSyncOptionsWithBufferEncoding,
1441
1441
  ): SpawnSyncReturns<Buffer>;
1442
1442
  function spawnSync(
1443
1443
  command: string,
1444
- args?: ReadonlyArray<string>,
1444
+ args?: readonly string[],
1445
1445
  options?: SpawnSyncOptions,
1446
1446
  ): SpawnSyncReturns<string | Buffer>;
1447
1447
  interface CommonExecOptions extends CommonOptions {
@@ -1522,18 +1522,18 @@ declare module "child_process" {
1522
1522
  function execFileSync(file: string, options: ExecFileSyncOptionsWithStringEncoding): string;
1523
1523
  function execFileSync(file: string, options: ExecFileSyncOptionsWithBufferEncoding): Buffer;
1524
1524
  function execFileSync(file: string, options?: ExecFileSyncOptions): string | Buffer;
1525
- function execFileSync(file: string, args: ReadonlyArray<string>): Buffer;
1525
+ function execFileSync(file: string, args: readonly string[]): Buffer;
1526
1526
  function execFileSync(
1527
1527
  file: string,
1528
- args: ReadonlyArray<string>,
1528
+ args: readonly string[],
1529
1529
  options: ExecFileSyncOptionsWithStringEncoding,
1530
1530
  ): string;
1531
1531
  function execFileSync(
1532
1532
  file: string,
1533
- args: ReadonlyArray<string>,
1533
+ args: readonly string[],
1534
1534
  options: ExecFileSyncOptionsWithBufferEncoding,
1535
1535
  ): Buffer;
1536
- function execFileSync(file: string, args?: ReadonlyArray<string>, options?: ExecFileSyncOptions): string | Buffer;
1536
+ function execFileSync(file: string, args?: readonly string[], options?: ExecFileSyncOptions): string | Buffer;
1537
1537
  }
1538
1538
  declare module "node:child_process" {
1539
1539
  export * from "child_process";
node/console.d.ts CHANGED
@@ -250,7 +250,7 @@ declare module "node:console" {
250
250
  * @since v10.0.0
251
251
  * @param properties Alternate properties for constructing the table.
252
252
  */
253
- table(tabularData: any, properties?: ReadonlyArray<string>): void;
253
+ table(tabularData: any, properties?: readonly string[]): void;
254
254
  /**
255
255
  * Starts a timer that can be used to compute the duration of an operation. Timers
256
256
  * are identified by a unique `label`. Use the same `label` when calling {@link timeEnd} to stop the timer and output the elapsed time in
node/crypto.d.ts CHANGED
@@ -4208,7 +4208,7 @@ declare module "crypto" {
4208
4208
  | HkdfParams
4209
4209
  | Pbkdf2Params,
4210
4210
  extractable: boolean,
4211
- keyUsages: ReadonlyArray<KeyUsage>,
4211
+ keyUsages: readonly KeyUsage[],
4212
4212
  ): Promise<CryptoKey>;
4213
4213
  /**
4214
4214
  * Using the method identified by `algorithm`, `subtle.digest()` attempts to generate a digest of `data`.
@@ -4288,12 +4288,12 @@ declare module "crypto" {
4288
4288
  generateKey(
4289
4289
  algorithm: RsaHashedKeyGenParams | EcKeyGenParams,
4290
4290
  extractable: boolean,
4291
- keyUsages: ReadonlyArray<KeyUsage>,
4291
+ keyUsages: readonly KeyUsage[],
4292
4292
  ): Promise<CryptoKeyPair>;
4293
4293
  generateKey(
4294
4294
  algorithm: AesKeyGenParams | HmacKeyGenParams | Pbkdf2Params,
4295
4295
  extractable: boolean,
4296
- keyUsages: ReadonlyArray<KeyUsage>,
4296
+ keyUsages: readonly KeyUsage[],
4297
4297
  ): Promise<CryptoKey>;
4298
4298
  generateKey(
4299
4299
  algorithm: AlgorithmIdentifier,
@@ -4320,7 +4320,7 @@ declare module "crypto" {
4320
4320
  | HmacImportParams
4321
4321
  | AesKeyAlgorithm,
4322
4322
  extractable: boolean,
4323
- keyUsages: ReadonlyArray<KeyUsage>,
4323
+ keyUsages: readonly KeyUsage[],
4324
4324
  ): Promise<CryptoKey>;
4325
4325
  importKey(
4326
4326
  format: Exclude<KeyFormat, "jwk">,
node/dgram.d.ts CHANGED
@@ -342,18 +342,18 @@ declare module "dgram" {
342
342
  * @param callback Called when the message has been sent.
343
343
  */
344
344
  send(
345
- msg: string | Uint8Array | ReadonlyArray<any>,
345
+ msg: string | Uint8Array | readonly any[],
346
346
  port?: number,
347
347
  address?: string,
348
348
  callback?: (error: Error | null, bytes: number) => void,
349
349
  ): void;
350
350
  send(
351
- msg: string | Uint8Array | ReadonlyArray<any>,
351
+ msg: string | Uint8Array | readonly any[],
352
352
  port?: number,
353
353
  callback?: (error: Error | null, bytes: number) => void,
354
354
  ): void;
355
355
  send(
356
- msg: string | Uint8Array | ReadonlyArray<any>,
356
+ msg: string | Uint8Array | readonly any[],
357
357
  callback?: (error: Error | null, bytes: number) => void,
358
358
  ): void;
359
359
  send(
node/dns/promises.d.ts CHANGED
@@ -307,6 +307,14 @@ declare module "dns/promises" {
307
307
  * @since v10.6.0
308
308
  */
309
309
  function reverse(ip: string): Promise<string[]>;
310
+ /**
311
+ * Get the default value for `verbatim` in {@link lookup} and `dnsPromises.lookup()`. The value could be:
312
+ *
313
+ * * `ipv4first`: for `verbatim` defaulting to `false`.
314
+ * * `verbatim`: for `verbatim` defaulting to `true`.
315
+ * @since v20.1.0
316
+ */
317
+ function getDefaultResultOrder(): "ipv4first" | "verbatim";
310
318
  /**
311
319
  * Sets the IP address and port of servers to be used when performing DNS
312
320
  * resolution. The `servers` argument is an array of [RFC 5952](https://tools.ietf.org/html/rfc5952#section-6) formatted
@@ -333,7 +341,7 @@ declare module "dns/promises" {
333
341
  * @since v10.6.0
334
342
  * @param servers array of `RFC 5952` formatted addresses
335
343
  */
336
- function setServers(servers: ReadonlyArray<string>): void;
344
+ function setServers(servers: readonly string[]): void;
337
345
  /**
338
346
  * Set the default value of `verbatim` in `dns.lookup()` and `dnsPromises.lookup()`. The value could be:
339
347
  *
node/dns.d.ts CHANGED
@@ -661,7 +661,7 @@ declare module "dns" {
661
661
  * @since v0.11.3
662
662
  * @param servers array of `RFC 5952` formatted addresses
663
663
  */
664
- export function setServers(servers: ReadonlyArray<string>): void;
664
+ export function setServers(servers: readonly string[]): void;
665
665
  /**
666
666
  * Returns an array of IP address strings, formatted according to [RFC 5952](https://tools.ietf.org/html/rfc5952#section-6),
667
667
  * that are currently configured for DNS resolution. A string will include a port
node/fs/promises.d.ts CHANGED
@@ -442,14 +442,14 @@ declare module "fs/promises" {
442
442
  * @param [position='null'] The offset from the beginning of the file where the data from `buffers` should be written. If `position` is not a `number`, the data will be written at the current
443
443
  * position.
444
444
  */
445
- writev(buffers: ReadonlyArray<NodeJS.ArrayBufferView>, position?: number): Promise<WriteVResult>;
445
+ writev(buffers: readonly NodeJS.ArrayBufferView[], position?: number): Promise<WriteVResult>;
446
446
  /**
447
447
  * Read from a file and write to an array of [ArrayBufferView](https://developer.mozilla.org/en-US/docs/Web/API/ArrayBufferView) s
448
448
  * @since v13.13.0, v12.17.0
449
449
  * @param [position='null'] The offset from the beginning of the file where the data should be read from. If `position` is not a `number`, the data will be read from the current position.
450
450
  * @return Fulfills upon success an object containing two properties:
451
451
  */
452
- readv(buffers: ReadonlyArray<NodeJS.ArrayBufferView>, position?: number): Promise<ReadVResult>;
452
+ readv(buffers: readonly NodeJS.ArrayBufferView[], position?: number): Promise<ReadVResult>;
453
453
  /**
454
454
  * Closes the file handle after waiting for any pending operation on the handle to
455
455
  * complete.
node/fs.d.ts CHANGED
@@ -4029,12 +4029,12 @@ declare module "fs" {
4029
4029
  */
4030
4030
  export function writev(
4031
4031
  fd: number,
4032
- buffers: ReadonlyArray<NodeJS.ArrayBufferView>,
4032
+ buffers: readonly NodeJS.ArrayBufferView[],
4033
4033
  cb: (err: NodeJS.ErrnoException | null, bytesWritten: number, buffers: NodeJS.ArrayBufferView[]) => void,
4034
4034
  ): void;
4035
4035
  export function writev(
4036
4036
  fd: number,
4037
- buffers: ReadonlyArray<NodeJS.ArrayBufferView>,
4037
+ buffers: readonly NodeJS.ArrayBufferView[],
4038
4038
  position: number,
4039
4039
  cb: (err: NodeJS.ErrnoException | null, bytesWritten: number, buffers: NodeJS.ArrayBufferView[]) => void,
4040
4040
  ): void;
@@ -4045,7 +4045,7 @@ declare module "fs" {
4045
4045
  export namespace writev {
4046
4046
  function __promisify__(
4047
4047
  fd: number,
4048
- buffers: ReadonlyArray<NodeJS.ArrayBufferView>,
4048
+ buffers: readonly NodeJS.ArrayBufferView[],
4049
4049
  position?: number,
4050
4050
  ): Promise<WriteVResult>;
4051
4051
  }
@@ -4056,7 +4056,7 @@ declare module "fs" {
4056
4056
  * @param [position='null']
4057
4057
  * @return The number of bytes written.
4058
4058
  */
4059
- export function writevSync(fd: number, buffers: ReadonlyArray<NodeJS.ArrayBufferView>, position?: number): number;
4059
+ export function writevSync(fd: number, buffers: readonly NodeJS.ArrayBufferView[], position?: number): number;
4060
4060
  /**
4061
4061
  * Read from a file specified by `fd` and write to an array of `ArrayBufferView`s
4062
4062
  * using `readv()`.
@@ -4074,12 +4074,12 @@ declare module "fs" {
4074
4074
  */
4075
4075
  export function readv(
4076
4076
  fd: number,
4077
- buffers: ReadonlyArray<NodeJS.ArrayBufferView>,
4077
+ buffers: readonly NodeJS.ArrayBufferView[],
4078
4078
  cb: (err: NodeJS.ErrnoException | null, bytesRead: number, buffers: NodeJS.ArrayBufferView[]) => void,
4079
4079
  ): void;
4080
4080
  export function readv(
4081
4081
  fd: number,
4082
- buffers: ReadonlyArray<NodeJS.ArrayBufferView>,
4082
+ buffers: readonly NodeJS.ArrayBufferView[],
4083
4083
  position: number,
4084
4084
  cb: (err: NodeJS.ErrnoException | null, bytesRead: number, buffers: NodeJS.ArrayBufferView[]) => void,
4085
4085
  ): void;
@@ -4090,7 +4090,7 @@ declare module "fs" {
4090
4090
  export namespace readv {
4091
4091
  function __promisify__(
4092
4092
  fd: number,
4093
- buffers: ReadonlyArray<NodeJS.ArrayBufferView>,
4093
+ buffers: readonly NodeJS.ArrayBufferView[],
4094
4094
  position?: number,
4095
4095
  ): Promise<ReadVResult>;
4096
4096
  }
@@ -4101,7 +4101,7 @@ declare module "fs" {
4101
4101
  * @param [position='null']
4102
4102
  * @return The number of bytes read.
4103
4103
  */
4104
- export function readvSync(fd: number, buffers: ReadonlyArray<NodeJS.ArrayBufferView>, position?: number): number;
4104
+ export function readvSync(fd: number, buffers: readonly NodeJS.ArrayBufferView[], position?: number): number;
4105
4105
 
4106
4106
  export interface OpenAsBlobOptions {
4107
4107
  /**
node/http.d.ts CHANGED
@@ -586,7 +586,7 @@ declare module "http" {
586
586
  * @param name Header name
587
587
  * @param value Header value
588
588
  */
589
- setHeader(name: string, value: number | string | ReadonlyArray<string>): this;
589
+ setHeader(name: string, value: number | string | readonly string[]): this;
590
590
  /**
591
591
  * Append a single header value for the header object.
592
592
  *
@@ -602,7 +602,7 @@ declare module "http" {
602
602
  * @param name Header name
603
603
  * @param value Header value
604
604
  */
605
- appendHeader(name: string, value: string | ReadonlyArray<string>): this;
605
+ appendHeader(name: string, value: string | readonly string[]): this;
606
606
  /**
607
607
  * Gets the value of the HTTP header with the given name. If that header is not
608
608
  * set, the returned value will be `undefined`.
node/http2.d.ts CHANGED
@@ -55,6 +55,7 @@ declare module "http2" {
55
55
  length: number;
56
56
  }
57
57
  export interface ServerStreamFileResponseOptions {
58
+ // eslint-disable-next-line @typescript-eslint/no-invalid-void-type
58
59
  statCheck?(stats: fs.Stats, headers: OutgoingHttpHeaders, statOptions: StatOptions): void | boolean;
59
60
  waitForTrailers?: boolean | undefined;
60
61
  offset?: number | undefined;
@@ -977,7 +978,7 @@ declare module "http2" {
977
978
  ): this;
978
979
  addListener(event: string | symbol, listener: (...args: any[]) => void): this;
979
980
  emit(event: "altsvc", alt: string, origin: string, stream: number): boolean;
980
- emit(event: "origin", origins: ReadonlyArray<string>): boolean;
981
+ emit(event: "origin", origins: readonly string[]): boolean;
981
982
  emit(event: "connect", session: ClientHttp2Session, socket: net.Socket | tls.TLSSocket): boolean;
982
983
  emit(
983
984
  event: "stream",
@@ -1415,7 +1416,7 @@ declare module "http2" {
1415
1416
  stream: ServerHttp2Stream,
1416
1417
  headers: IncomingHttpHeaders,
1417
1418
  options: stream.ReadableOptions,
1418
- rawHeaders: ReadonlyArray<string>,
1419
+ rawHeaders: readonly string[],
1419
1420
  );
1420
1421
  /**
1421
1422
  * The `request.aborted` property will be `true` if the request has
@@ -1856,7 +1857,7 @@ declare module "http2" {
1856
1857
  * ```
1857
1858
  * @since v8.4.0
1858
1859
  */
1859
- setHeader(name: string, value: number | string | ReadonlyArray<string>): void;
1860
+ setHeader(name: string, value: number | string | readonly string[]): void;
1860
1861
  /**
1861
1862
  * Sets the `Http2Stream`'s timeout value to `msecs`. If a callback is
1862
1863
  * provided, then it is added as a listener on the `'timeout'` event on
node/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "20.9.2",
3
+ "version": "20.9.4",
4
4
  "description": "TypeScript definitions for node",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
6
6
  "license": "MIT",
@@ -224,7 +224,7 @@
224
224
  "dependencies": {
225
225
  "undici-types": "~5.26.4"
226
226
  },
227
- "typesPublisherContentHash": "24437ac82ce1804878c3e265b2d5ef55f5f475c0333622a181647c43bd4d835e",
227
+ "typesPublisherContentHash": "95411fad5f792ee5e5fa2a909e47e611c12b24e5092a93d58b48acf1e08ef869",
228
228
  "typeScriptVersion": "4.5",
229
229
  "nonNpm": true
230
230
  }
node/perf_hooks.d.ts CHANGED
@@ -460,7 +460,7 @@ declare module "perf_hooks" {
460
460
  observe(
461
461
  options:
462
462
  | {
463
- entryTypes: ReadonlyArray<EntryType>;
463
+ entryTypes: readonly EntryType[];
464
464
  buffered?: boolean | undefined;
465
465
  }
466
466
  | {
node/punycode.d.ts CHANGED
@@ -101,7 +101,7 @@ declare module "punycode" {
101
101
  * Users currently depending on the punycode module should switch to using
102
102
  * the userland-provided Punycode.js module instead.
103
103
  */
104
- encode(codePoints: ReadonlyArray<number>): string;
104
+ encode(codePoints: readonly number[]): string;
105
105
  }
106
106
  /**
107
107
  * @deprecated since v7.0.0
node/querystring.d.ts CHANGED
@@ -25,9 +25,9 @@ declare module "querystring" {
25
25
  | string
26
26
  | number
27
27
  | boolean
28
- | ReadonlyArray<string>
29
- | ReadonlyArray<number>
30
- | ReadonlyArray<boolean>
28
+ | readonly string[]
29
+ | readonly number[]
30
+ | readonly boolean[]
31
31
  | null
32
32
  >
33
33
  {}
node/timers.d.ts CHANGED
@@ -155,7 +155,7 @@ declare module "timers" {
155
155
  ...args: TArgs
156
156
  ): NodeJS.Timeout;
157
157
  // util.promisify no rest args compability
158
- // tslint:disable-next-line void-return
158
+ // eslint-disable-next-line @typescript-eslint/no-invalid-void-type
159
159
  function setTimeout(callback: (args: void) => void, ms?: number): NodeJS.Timeout;
160
160
  namespace setTimeout {
161
161
  const __promisify__: typeof setTimeoutPromise;
@@ -187,7 +187,7 @@ declare module "timers" {
187
187
  ...args: TArgs
188
188
  ): NodeJS.Timeout;
189
189
  // util.promisify no rest args compability
190
- // tslint:disable-next-line void-return
190
+ // eslint-disable-next-line @typescript-eslint/no-invalid-void-type
191
191
  function setInterval(callback: (args: void) => void, ms?: number): NodeJS.Timeout;
192
192
  namespace setInterval {
193
193
  const __promisify__: typeof setIntervalPromise;
@@ -221,7 +221,7 @@ declare module "timers" {
221
221
  ...args: TArgs
222
222
  ): NodeJS.Immediate;
223
223
  // util.promisify no rest args compability
224
- // tslint:disable-next-line void-return
224
+ // eslint-disable-next-line @typescript-eslint/no-invalid-void-type
225
225
  function setImmediate(callback: (args: void) => void): NodeJS.Immediate;
226
226
  namespace setImmediate {
227
227
  const __promisify__: typeof setImmediatePromise;
node/tls.d.ts CHANGED
@@ -1203,7 +1203,7 @@ declare module "tls" {
1203
1203
  * format) used for verifying peer certificates. This is the default value
1204
1204
  * of the ca option to tls.createSecureContext().
1205
1205
  */
1206
- const rootCertificates: ReadonlyArray<string>;
1206
+ const rootCertificates: readonly string[];
1207
1207
  }
1208
1208
  declare module "node:tls" {
1209
1209
  export * from "tls";
node/ts4.8/assert.d.ts CHANGED
@@ -45,7 +45,7 @@ declare module "assert" {
45
45
  /** The `operator` property on the error instance. */
46
46
  operator?: string | undefined;
47
47
  /** If provided, the generated stack trace omits frames before this function. */
48
- // tslint:disable-next-line:ban-types
48
+ // eslint-disable-next-line @typescript-eslint/ban-types
49
49
  stackStartFn?: Function | undefined;
50
50
  });
51
51
  }
@@ -228,7 +228,7 @@ declare module "assert" {
228
228
  expected: unknown,
229
229
  message?: string | Error,
230
230
  operator?: string,
231
- // tslint:disable-next-line:ban-types
231
+ // eslint-disable-next-line @typescript-eslint/ban-types
232
232
  stackStartFn?: Function,
233
233
  ): never;
234
234
  /**