Open micalevisk opened 2 years ago
I do agree with this comment
Implicit coercing for the rest arguments is not a good default and should be off by default.
Thus we can add this new option using false
by default, and then changing it to true
in the next major relase.
I would vote on keeping the original behavior just to not introduce a breaking change, but having an option to control that is definitely a good idea.
I believe this will fix this other issue: https://github.com/substack/minimist/issues/112
$ node example/parse.js 002e1234
{ _: [ Infinity ] }
Original issue by @whitlockjc at https://github.com/substack/minimist/issues/36
If I invoke my command using
my-command 2.3
, I end up with something like this:I realize if this was an option I could use
opts.string
to tell minimist to treat my option as a string but looks like there's no way to achieve the same for argument.What I expect instead: