We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
I'd like to be able to just specify a type (eg. String), without making it an array String (eg. [String])
String
[String]
I'd like to be able to do:
const cli = cac('cli') .option('--size <size>', 'Size', { type: String, })
and get the parsed options:
{ '--': [], size: '16' }
Instead, I currently must do
const cli = cac('cli') .option('--size <size>', 'Size', { type: [String], })
{ '--': [], size: ['16'] }
as communicated by the type:
cac/src/Option.ts
Line 5 in f51fc22
The text was updated successfully, but these errors were encountered:
Ah yes, I actually forgot why it was designed to be an array by default 😅
Sorry, something went wrong.
It also confuses me...🤔
No branches or pull requests
Issue Type
Expected
I'd like to be able to just specify a type (eg.
String
), without making it an array String (eg.[String]
)I'd like to be able to do:
and get the parsed options:
Actual
Instead, I currently must do
and get the parsed options:
as communicated by the type:
cac/src/Option.ts
Line 5 in f51fc22
Possible Solutions
Info
The text was updated successfully, but these errors were encountered: