You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Ok, I wrote an example for this and in doing so figured out what I was doing wrong.
I added an optional parameter and expected it to be universal. That is to say: by adding it at an intermediate level, have it be available at all lower levels. But that's not a reasonable assumption, it has to be define in the final form of the command.
I'm using a commandDir(), as described here: https://github.com/yargs/yargs/blob/main/docs/advanced.md
My layout is similar to the one in the example:
With this example, say I've got a positional argument in
add.js
, at the most bottom level.I filled in the builder export, gave it a description, in order to show the help message for it. But it doesn't show up.
It does show up if I move that description to the builder export of
remote.js
, one level above it.Since the argument only makes sense in context of
add.js
, that's where I added the description. But it only shows up if added the level above it.Is this expected? Am I misunderstanding something? Or did I stumble across a bug?
The text was updated successfully, but these errors were encountered: