feat: split demand() into demandCommand()/demandOption()#740
Conversation
|
@ljharb sorry this turned into a never ending yak shave! The Any ways, months overdue but I think this gets things to what you pushed us towards. Thanks @lrlna for the hard work 🎉 |
|
Thanks to everybody :-) I look forward to consuming it once it's released. |
|
@bcoe are you doing this one as a major though? Or with |
|
@lrlna since we opted to keep the
|
|
@bcoe I think that sounds like a good plan. What do you think when should we take action about the readme refactoring? |
|
@maxrimue I approve of this message; I've noticed a lot of big JS projects have moved towards smaller READMEs with external doc sites. |
|
@maxrimue want to start pulling together a |
|
@bcoe on it |
|
As of 6.6.0, |
|
@kumar303 mind sharing the syntax that had a regression for you, I'd like to patch this in the |
|
Sure, here is a script to reproduce it: var yargs = require('yargs');
yargs
.help('help')
.demand(0, 0, 'This is a custom message to explain the error better')
.strict()
.argv;In In |
|
@kumar303 thank you; I'll get a regression test written this evening. |
Getting @lrlna's wonderful work on splitting
demand()intodemandCommand()/demandOption()over the finish line.Everything is %99 of the way there, just addressing some final nits from @maxrimue and myself -- excited to try to get yargs down to a few less open issue.
TODO:
demandmessage is provided, gsub in “got” and “count” #438.fixes #504, #431 follow up with #618