@types/node 22.5.4 → 22.5.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. node/README.md +1 -1
  2. node/package.json +2 -2
  3. node/util.d.ts +8 -5
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: Wed, 04 Sep 2024 21:35:57 GMT
11
+ * Last updated: Sat, 14 Sep 2024 00:53:13 GMT
12
12
  * Dependencies: [undici-types](https://npmjs.com/package/undici-types)
13
13
 
14
14
  # Credits
node/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/node",
3
- "version": "22.5.4",
3
+ "version": "22.5.5",
4
4
  "description": "TypeScript definitions for node",
5
5
  "homepage": "https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/node",
6
6
  "license": "MIT",
@@ -212,6 +212,6 @@
212
212
  "dependencies": {
213
213
  "undici-types": "~6.19.2"
214
214
  },
215
- "typesPublisherContentHash": "6ee9a11eba834031423800320320aa873d6bf2b6f33603c13a2aa9d90b3803ee",
215
+ "typesPublisherContentHash": "49c6854801c6eca5f0c4debaa90673195b7385ea09dc082e76a86be2fa20430f",
216
216
  "typeScriptVersion": "4.8"
217
217
  }
node/util.d.ts CHANGED
@@ -1520,11 +1520,14 @@ declare module "util" {
1520
1520
  type ParsedValues<T extends ParseArgsConfig> =
1521
1521
  & IfDefaultsTrue<T["strict"], unknown, { [longOption: string]: undefined | string | boolean }>
1522
1522
  & (T["options"] extends ParseArgsOptionsConfig ? {
1523
- -readonly [LongOption in keyof T["options"]]: IfDefaultsFalse<
1524
- T["options"][LongOption]["multiple"],
1525
- undefined | Array<ExtractOptionValue<T, T["options"][LongOption]>>,
1526
- undefined | ExtractOptionValue<T, T["options"][LongOption]>
1527
- >;
1523
+ -readonly [LongOption in keyof T["options"]]:
1524
+ // when "default" is not undefined, the value will be present
1525
+ | (T["options"][LongOption]["default"] extends {} ? never : undefined)
1526
+ | IfDefaultsFalse<
1527
+ T["options"][LongOption]["multiple"],
1528
+ Array<ExtractOptionValue<T, T["options"][LongOption]>>,
1529
+ ExtractOptionValue<T, T["options"][LongOption]>
1530
+ >;
1528
1531
  }
1529
1532
  : {});
1530
1533