@shadow-dev/core
Version:
A modular core framework for Discord bot development, providing commands, buttons, menus, middleware, and more.
14 lines (13 loc) • 665 B
TypeScript
import { ChatInputCommandInteraction } from "discord.js";
import { Command } from "../command";
export interface ICommandMiddleware {
name: string;
beforeExecution: (interaction: ChatInputCommandInteraction, command: Command) => Promise<boolean>;
afterExecution: (interaction: ChatInputCommandInteraction, command: Command) => Promise<void>;
}
export declare class CommandMiddleware {
name: string;
beforeExecution: (interaction: ChatInputCommandInteraction, command: Command) => Promise<boolean>;
afterExecution: (interaction: ChatInputCommandInteraction, command: Command) => Promise<void>;
constructor(options: ICommandMiddleware);
}