Skip to content

Commit 38ce249

Browse files
bakkotaduh95
authored andcommitted
doc: expand description of parseArg's default
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>
1 parent e5ba216 commit 38ce249

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

doc/api/util.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1535,9 +1535,10 @@ changes:
15351535
times. If `true`, all values will be collected in an array. If
15361536
`false`, values for the option are last-wins. **Default:** `false`.
15371537
* `short` {string} A single character alias for the option.
1538-
* `default` {string | boolean | string\[] | boolean\[]} The default option
1539-
value when it is not set by args. It must be of the same type as the
1540-
`type` property. When `multiple` is `true`, it must be an array.
1538+
* `default` {string | boolean | string\[] | boolean\[]} The default value to
1539+
be used if (and only if) the option does not appear in the arguments to be
1540+
parsed. It must be of the same type as the `type` property. When `multiple`
1541+
is `true`, it must be an array.
15411542
* `strict` {boolean} Should an error be thrown when unknown arguments
15421543
are encountered, or when arguments are passed that do not match the
15431544
`type` configured in `options`.

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy