Functioncorev0.14.0Decorator
StringMenuRoute
Routes string select menu interactions to a StringMenuHandler.
Pass the CustomId definition(s) this handler decodes and list the same ones in the handler's
generic. Read the chosen option values from this.values.
StringMenuRoute<Defs>(
defs: Defs
): <TCtor extends AnyHandlerCtor>(
constructor: AssertComponentRoute<InteractionKind.StringMenu, Defs, TCtor>
) => void\@StringMenuRoute(TopicsId)
class Topics extends StringMenuHandler<[typeof TopicsId]> {
async execute() {
await this.update(`following ${this.values.join(', ')}`);
}
}Defs
Defsdefs
defs: DefsThe customId definition(s) this handler decodes, one per route.