Skip to content

Commit

Permalink
doc: expand description of parseArg's default
Browse files Browse the repository at this point in the history
PR-URL: #54431
Reviewed-By: James M Snell <jasnell@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Jordan Harband <ljharb@gmail.com>
  • Loading branch information
bakkot authored and aduh95 committed Jan 2, 2025
1 parent e5ba216 commit 38ce249
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions doc/api/util.md
Original file line number Diff line number Diff line change
Expand Up @@ -1535,9 +1535,10 @@ changes:
times. If `true`, all values will be collected in an array. If
`false`, values for the option are last-wins. **Default:** `false`.
* `short` {string} A single character alias for the option.
* `default` {string | boolean | string\[] | boolean\[]} The default option
value when it is not set by args. It must be of the same type as the
`type` property. When `multiple` is `true`, it must be an array.
* `default` {string | boolean | string\[] | boolean\[]} The default value to
be used if (and only if) the option does not appear in the arguments to be
parsed. It must be of the same type as the `type` property. When `multiple`
is `true`, it must be an array.
* `strict` {boolean} Should an error be thrown when unknown arguments
are encountered, or when arguments are passed that do not match the
`type` configured in `options`.
Expand Down

0 comments on commit 38ce249

Please sign in to comment.