added default logger

This commit is contained in:
jacoobes
2022-02-07 23:55:16 -06:00
parent 07018b6d09
commit 09bf5a1bfe
5 changed files with 55 additions and 13 deletions

View File

@@ -4,9 +4,8 @@ import type * as Sern from "../handler/sern"
export type Visibility = "private" | "public"
//Anything that can be sent in a `<TextChannel>#send` or `<CommandInteraction>#reply`
export type possibleOutput = string | MessagePayload & MessageOptions;
export type possibleOutput<T = string> = T | MessagePayload & MessageOptions;
export type Nullable<T> = T | null;
export type delegate = Sern.Module<unknown>["delegate"]
/// Thanks @cursorsdottsx
@@ -16,12 +15,9 @@ export type ParseType<T> = {
// A Sern.Module["delegate"] will carry a Context Parameter
export type Context = {
text: Option<Message>,
slash: Option<CommandInteraction>
}
export interface Arg {
text: string;
slash: SlashOptions
message: Option<Message>,
interaction: Option<CommandInteraction>
}
export type Arg = ParseType<{text : string, slash : SlashOptions}>
// TypeAlias for interaction.options
export type SlashOptions = Omit<CommandInteractionOptionResolver, "getMessage" | "getFocused">;