import type { CommandInteractionOptionResolver, MessagePayload, MessageOptions, } from 'discord.js'; import type Module from '../handler/module'; export type Visibility = 'private' | 'public'; // Anything that can be sent in a `#send` or `#reply` export type possibleOutput = T | (MessagePayload & MessageOptions); export type execute = Module['execute']; // Thanks @cursorsdottsx export type ParseType = { [K in keyof T]: T[K] extends unknown ? [k: K, args: T[K]] : never; }[keyof T]; export type Arg = ParseType<{ text: string[]; slash: SlashOptions }>; // TypeAlias for interaction.options export type SlashOptions = Omit;