@types/node 18.19.114 → 18.19.116

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 v18.19/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/v18.
9
9
 
10
10
  ### Additional Details
11
- * Last updated: Tue, 01 Jul 2025 19:02:07 GMT
11
+ * Last updated: Tue, 08 Jul 2025 17:03:33 GMT
12
12
  * Dependencies: [undici-types](https://npmjs.com/package/undici-types)
13
13
 
14
14
  # Credits
node v18.19/buffer.d.ts CHANGED
@@ -1680,6 +1680,8 @@ declare module "buffer" {
1680
1680
  * @return A reference to `buf`.
1681
1681
  */
1682
1682
  fill(value: string | Uint8Array | number, offset?: number, end?: number, encoding?: BufferEncoding): this;
1683
+ fill(value: string | Uint8Array | number, offset: number, encoding: BufferEncoding): this;
1684
+ fill(value: string | Uint8Array | number, encoding: BufferEncoding): this;
1683
1685
  /**
1684
1686
  * If `value` is:
1685
1687
  *
@@ -126,22 +126,24 @@ declare module "dns/promises" {
126
126
  * @param [rrtype='A'] Resource record type.
127
127
  */
128
128
  function resolve(hostname: string): Promise<string[]>;
129
- function resolve(hostname: string, rrtype: "A"): Promise<string[]>;
130
- function resolve(hostname: string, rrtype: "AAAA"): Promise<string[]>;
129
+ function resolve(hostname: string, rrtype: "A" | "AAAA" | "CNAME" | "NS" | "PTR"): Promise<string[]>;
131
130
  function resolve(hostname: string, rrtype: "ANY"): Promise<AnyRecord[]>;
132
131
  function resolve(hostname: string, rrtype: "CAA"): Promise<CaaRecord[]>;
133
- function resolve(hostname: string, rrtype: "CNAME"): Promise<string[]>;
134
132
  function resolve(hostname: string, rrtype: "MX"): Promise<MxRecord[]>;
135
133
  function resolve(hostname: string, rrtype: "NAPTR"): Promise<NaptrRecord[]>;
136
- function resolve(hostname: string, rrtype: "NS"): Promise<string[]>;
137
- function resolve(hostname: string, rrtype: "PTR"): Promise<string[]>;
138
134
  function resolve(hostname: string, rrtype: "SOA"): Promise<SoaRecord>;
139
135
  function resolve(hostname: string, rrtype: "SRV"): Promise<SrvRecord[]>;
140
136
  function resolve(hostname: string, rrtype: "TXT"): Promise<string[][]>;
141
- function resolve(
142
- hostname: string,
143
- rrtype: string,
144
- ): Promise<string[] | MxRecord[] | NaptrRecord[] | SoaRecord | SrvRecord[] | string[][] | AnyRecord[]>;
137
+ function resolve(hostname: string, rrtype: string): Promise<
138
+ | string[]
139
+ | CaaRecord[]
140
+ | MxRecord[]
141
+ | NaptrRecord[]
142
+ | SoaRecord
143
+ | SrvRecord[]
144
+ | string[][]
145
+ | AnyRecord[]
146
+ >;
145
147
  /**
146
148
  * Uses the DNS protocol to resolve IPv4 addresses (`A` records) for the `hostname`. On success, the `Promise` is resolved with an array of IPv4
147
149
  * addresses (e.g. `['74.125.79.104', '74.125.79.105', '74.125.79.106']`).
node v18.19/dns.d.ts CHANGED
@@ -240,6 +240,9 @@ declare module "dns" {
240
240
  contactemail?: string | undefined;
241
241
  contactphone?: string | undefined;
242
242
  }
243
+ export interface AnyCaaRecord extends CaaRecord {
244
+ type: "CAA";
245
+ }
243
246
  export interface MxRecord {
244
247
  priority: number;
245
248
  exchange: string;
@@ -298,6 +301,7 @@ declare module "dns" {
298
301
  export type AnyRecord =
299
302
  | AnyARecord
300
303
  | AnyAaaaRecord
304
+ | AnyCaaRecord
301
305
  | AnyCnameRecord
302
306
  | AnyMxRecord
303
307
  | AnyNaptrRecord
@@ -325,12 +329,7 @@ declare module "dns" {
325
329
  ): void;
326
330
  export function resolve(
327
331
  hostname: string,
328
- rrtype: "A",
329
- callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
330
- ): void;
331
- export function resolve(
332
- hostname: string,
333
- rrtype: "AAAA",
332
+ rrtype: "A" | "AAAA" | "CNAME" | "NS" | "PTR",
334
333
  callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
335
334
  ): void;
336
335
  export function resolve(
@@ -340,8 +339,8 @@ declare module "dns" {
340
339
  ): void;
341
340
  export function resolve(
342
341
  hostname: string,
343
- rrtype: "CNAME",
344
- callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
342
+ rrtype: "CAA",
343
+ callback: (err: NodeJS.ErrnoException | null, address: CaaRecord[]) => void,
345
344
  ): void;
346
345
  export function resolve(
347
346
  hostname: string,
@@ -353,16 +352,6 @@ declare module "dns" {
353
352
  rrtype: "NAPTR",
354
353
  callback: (err: NodeJS.ErrnoException | null, addresses: NaptrRecord[]) => void,
355
354
  ): void;
356
- export function resolve(
357
- hostname: string,
358
- rrtype: "NS",
359
- callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
360
- ): void;
361
- export function resolve(
362
- hostname: string,
363
- rrtype: "PTR",
364
- callback: (err: NodeJS.ErrnoException | null, addresses: string[]) => void,
365
- ): void;
366
355
  export function resolve(
367
356
  hostname: string,
368
357
  rrtype: "SOA",
@@ -383,12 +372,21 @@ declare module "dns" {
383
372
  rrtype: string,
384
373
  callback: (
385
374
  err: NodeJS.ErrnoException | null,
386
- addresses: string[] | MxRecord[] | NaptrRecord[] | SoaRecord | SrvRecord[] | string[][] | AnyRecord[],
375
+ addresses:
376
+ | string[]
377
+ | CaaRecord[]
378
+ | MxRecord[]
379
+ | NaptrRecord[]
380
+ | SoaRecord
381
+ | SrvRecord[]
382
+ | string[][]
383
+ | AnyRecord[],
387
384
  ) => void,
388
385
  ): void;
389
386
  export namespace resolve {
390
387
  function __promisify__(hostname: string, rrtype?: "A" | "AAAA" | "CNAME" | "NS" | "PTR"): Promise<string[]>;
391
388
  function __promisify__(hostname: string, rrtype: "ANY"): Promise<AnyRecord[]>;
389
+ function __promisify__(hostname: string, rrtype: "CAA"): Promise<CaaRecord[]>;
392
390
  function __promisify__(hostname: string, rrtype: "MX"): Promise<MxRecord[]>;
393
391
  function __promisify__(hostname: string, rrtype: "NAPTR"): Promise<NaptrRecord[]>;
394
392
  function __promisify__(hostname: string, rrtype: "SOA"): Promise<SoaRecord>;
@@ -397,7 +395,16 @@ declare module "dns" {
397
395
  function __promisify__(
398
396
  hostname: string,
399
397
  rrtype: string,
400
- ): Promise<string[] | MxRecord[] | NaptrRecord[] | SoaRecord | SrvRecord[] | string[][] | AnyRecord[]>;
398
+ ): Promise<
399
+ | string[]
400
+ | CaaRecord[]
401
+ | MxRecord[]
402
+ | NaptrRecord[]
403
+ | SoaRecord
404
+ | SrvRecord[]
405
+ | string[][]
406
+ | AnyRecord[]
407
+ >;
401
408
  }
402
409
  /**
403
410
  * Uses the DNS protocol to resolve a IPv4 addresses (`A` records) for the `hostname`. The `addresses` argument passed to the `callback` function
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "18.19.114",
3
+ "version": "18.19.116",
4
4
  "description": "TypeScript definitions for node",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
6
6
  "license": "MIT",
@@ -220,6 +220,6 @@
220
220
  "undici-types": "~5.26.4"
221
221
  },
222
222
  "peerDependencies": {},
223
- "typesPublisherContentHash": "dacb8e8ec3578d7cf5eddd98cd34edcecc28555bdb654b4a9773ea0cca27ac75",
223
+ "typesPublisherContentHash": "efd6a31dc3af88f6fc679acca9b7bde34c8e99ad0a09ee98caa5fa25197a7814",
224
224
  "typeScriptVersion": "5.1"
225
225
  }