blackcat.js-discord - v1.0.10
    Preparing search index...

    Interface ISlashSubCommandBuilder<TOptions>

    Interface builder cho một Slash Subcommand.

    interface ISlashSubCommandBuilder<
        TOptions extends Record<string, any>
        | undefined = undefined,
    > {
        description: string;
        options?: TOptions;
        build(
            name: string,
            parent: SlashCommandBuilder | SlashCommandSubcommandGroupBuilder,
        ): void;
        parse(
            interaction: ChatInputCommandInteraction,
        ): TOptions extends Record<string, any> ? InferOptions<TOptions> : {};
    }

    Type Parameters

    • TOptions extends Record<string, any> | undefined = undefined

      danh sách option của subcommand

    Implemented by

    Index

    Properties

    Methods

    Properties

    description: string

    Mô tả subcommand

    options?: TOptions

    Danh sách option

    Methods

    • Build subcommand vào builder của Discord

      Parameters

      • name: string
      • parent: SlashCommandBuilder | SlashCommandSubcommandGroupBuilder

      Returns void

    • Parse option từ interaction

      Parameters

      • interaction: ChatInputCommandInteraction

      Returns TOptions extends Record<string, any> ? InferOptions<TOptions> : {}