Yurba.js Documentation
    Preparing search index...

    Type Alias CommandArgsSchema

    CommandArgsSchema: Record<
        string,
        CommandArgsSchemaEntry
        | string
        | [string, any?, "rest"?],
    >

    Defines the schema for command arguments. Can be an object with CommandArgsSchemaEntry, a string, or a tuple.

    // Using CommandArgsSchemaEntry objects
    {
    name: { type: 'string', required: true },
    age: { type: 'int', default: 18 }
    }
    // Using string shorthand
    {
    name: 'string',
    age: 'int'
    }
    // Using tuple notation
    {
    name: ['string', 'defaultName'],
    args: ['string', undefined, 'rest']
    }