Closed bakkot closed 2 years ago
I don't know if it should also apply to non-strict.
I think it applies for both strict and non-strict.
Per the original comment, the idea is to make the implicit configuration option illegal.
Implicit boolean type, no clues:
parseArgs({
options: {
foo: {},
},
});
Explicit:
parseArgs({
options: {
foo: { type: 'boolean' },
},
});
@bcoe suggested this here. I'm in favor of it, and wanted to open an issue for it so it doesn't get lost.
This would definitely apply to
strict
. I don't know if it should also apply to non-strict. I'm still not entirely clear on what non-strict is for, which makes it hard to judge what's right for it.I note that if if
type
is not required for non-strict, you have odd cases likewhere... would that give you
{ values: { foo: ['a', true] } }
, or what?