Functioncorev0.5.0Decorator
SlashRoute
Routes one or more slash commands to a SlashHandler.
Pass the same route string(s) as the handler's generic. A single command reads this.options, several commands branch with this.match. The decorator routes and the generic must match exactly. Listing fewer or more than the handler declares is a compile error. Subcommands use a slash path.
SlashRoute<Route>(
routes: Route[]
): <TCtor extends AnyHandlerCtor>(
constructor: AssertSlashRoute<Route, TCtor>
) => voidRoute
Routeroutes
routes: Route[]The route string(s) this handler serves, e.g. 'ban', 'ban', 'kick', or 'demo/setup'.