ex(arguments: 3) result(-a argument second third -h) result(--args argument second third -h)
Optional array
array:boolean
ex(-x 1 -x 2) result({ x: [1, 2] })
Optional cls
cls:Object
Optional count
count:boolean
ex(-vv -v) result({ v: 3 })
Optional default
default:any
Optional description
description:any
option description for help outout
Optional key
key:string
short 1 character key -k
Optional name
name:string
long --name
Optional transformer
transformer:Function
Optional type
type:KindOf
Casting and handling of option
boolean - arguments will be casted to boolean. if no arguments, if key/name is present it will be true, otherwise false.
string - arguments will be casted to string
number - arguments will be casted to number
ex(arguments: 3) result(-a argument second third -h) result(--args argument second third -h)