Page Not Found
We could not find what you were looking for.
Please contact the owner of the site that linked you to the original URL and let them know their link is broken.
diff --git a/404.html b/404.html index 6f23a2737..4595fdf03 100644 --- a/404.html +++ b/404.html @@ -1,20 +1,40 @@ - - -
- - -We could not find what you were looking for.
Please contact the owner of the site that linked you to the original URL and let them know their link is broken.
1.0.0 +Provides values shared between +Message and ChatInputCommandInteraction
+CoreContext<Message, ChatInputCommandInteraction>+++
getchannel():null|TextBasedChannel
null | TextBasedChannel
src/core/structures/context.ts:39
++++
getchannelId():string
string
src/core/structures/context.ts:45
++++
getclient():Client<boolean>
Client<boolean>
src/core/structures/context.ts:91
++++
getcreatedTimestamp():number
number
src/core/structures/context.ts:65
++++
getguild():null|Guild
null | Guild
src/core/structures/context.ts:71
++++
getguildId():null|string
null | string
src/core/structures/context.ts:77
++++
getid():string
string
src/core/structures/context.ts:33
++++
getinGuild():boolean
boolean
src/core/structures/context.ts:97
++++
getinteraction():I
I
src/core/structures/core-context.ts:15
++++
getmember():null|GuildMember|APIInteractionGuildMember
null | GuildMember | APIInteractionGuildMember
src/core/structures/context.ts:85
++++
getmessage():M
M
src/core/structures/core-context.ts:12
++++
getoptions():Omit<CommandInteractionOptionResolver<CacheType>,"getMessage"|"getFocused">
Omit<CommandInteractionOptionResolver<CacheType>, "getMessage" | "getFocused">
src/core/structures/context.ts:26
++++
getuser():User
If context is holding a message, message.author +else, interaction.user
+User
src/core/structures/context.ts:55
++++
getuserId():string
string
src/core/structures/context.ts:61
+++isMessage():
+this is CoreContext<Message<boolean>, never>
this is CoreContext<Message<boolean>, never>
CoreContext.isMessage
src/core/structures/core-context.ts:19
+++isSlash():
+this is CoreContext<never, ChatInputCommandInteraction<CacheType>>
this is CoreContext<never, ChatInputCommandInteraction<CacheType>>
CoreContext.isSlash
src/core/structures/core-context.ts:23
+++reply(
+content):Promise<Message<boolean>>
• content: ReplyOptions
Promise<Message<boolean>>
src/core/structures/context.ts:103
++++
staticwrap(wrappable):Context
• wrappable: Message<boolean> | BaseInteraction<CacheType>
CoreContext.wrap
++new ModuleStore():
+ModuleStore
++commands:
+Map<string,Module>
src/core/structures/module-store.ts:10
+++metadata:
+WeakMap<Module,CommandMeta>
1.0.0 +A bitfield that discriminates command modules
+1export default commandModule({2 // highlight-next-line3 type : CommandType.Text,4 name : 'a text command'5 execute(message) {6 console.log(message.content)7 }8})++Both:
+3
src/core/structures/enums.ts:20
+++Button:
+16
src/core/structures/enums.ts:23
+++ChannelSelect:
+1024
src/core/structures/enums.ts:29
+++CtxMsg:
+8
src/core/structures/enums.ts:22
+++CtxUser:
+4
src/core/structures/enums.ts:21
+++MentionableSelect:
+512
src/core/structures/enums.ts:28
+++Modal:
+64
src/core/structures/enums.ts:25
+++RoleSelect:
+256
src/core/structures/enums.ts:27
+++Slash:
+2
src/core/structures/enums.ts:19
+++StringSelect:
+32
src/core/structures/enums.ts:24
+++Text:
+1
src/core/structures/enums.ts:18
+++UserSelect:
+128
A bitfield that discriminates event modules
+1export default eventModule({2 //highlight-next-line3 type : EventType.Discord,4 name : 'guildMemberAdd'5 execute(member : GuildMember) {6 console.log(member)7 }8})++Discord:
+1
The EventType for handling discord events
+src/core/structures/enums.ts:51
+++External:
+3
The EventType for handling external events.
+Could be for example, process events, database events
src/core/structures/enums.ts:60
+++Sern:
+2
The EventType for handling sern events
+++Failure:
+"failure"
The PayloadType for a SernEmitter failure event
+src/core/structures/enums.ts:98
+++Success:
+"success"
The PayloadType for a SernEmitter success event
+src/core/structures/enums.ts:94
+++Warning:
+"warning"
The PayloadType for a SernEmitter warning event
+A bitfield that discriminates plugins
+1export default function myPlugin() : EventPlugin<CommandType.Text> {2 //highlight-next-line3 type : PluginType.Event,4 execute([ctx, args], controller) {5 return controller.next();6 }7}++Control:
+2
The PluginType for EventPlugins
+src/core/structures/enums.ts:85
+++Init:
+1
The PluginType for InitPlugins
+++CommandControlPlugin<
+I>(execute):Plugin<unknown[]>
• I extends CommandType
• execute
+Plugin<unknown[]>
2.5.0 +@PURE
+++CommandInitPlugin<
+I>(execute):Plugin<unknown[]>
• I extends CommandType
• execute
+Plugin<unknown[]>
2.5.0 +@PURE
+++commandModule(
+mod):CommandModule
• mod: InputCommand
1.0.0 The wrapper function to define command modules for sern
+++discordEvent<
+T>(mod):EventModule
Create event modules from discord.js client events, +This is an eventModule for discord events, +where typings can be very bad.
+• T extends keyof ClientEvents
• mod
+• mod.execute
+• mod.name: T
• mod.plugins?: AnyEventPlugin[]
++DiscordEventControlPlugin<
+T>(name,execute):Plugin<unknown[]>
• T extends keyof ClientEvents
• name: T
• execute
+Plugin<unknown[]>
2.5.0
+A specialized function for creating control plugins with discord.js ClientEvents. +Will probably be moved one day!
+++eventModule(
+mod):EventModule
• mod: InputEvent
1.0.0 +The wrapper function to define event modules for sern
+++makeDependencies<
+T>(conf):Promise<<V>(…keys) =>IntoDependencies<V>>
• T extends Dependencies
• conf: ValidDependencyConfig
Promise<<V>(…keys) => IntoDependencies<V>>
++makePlugin<
+V>(type,execute):Plugin<V>
• V extends unknown[]
• type: PluginType
• execute
+Plugin<V>
++Service<
+T>(key):NonNullable<UnpackFunction<Partial<Dependencies>[T]>>
The new Service api, a cleaner alternative to useContainer +To obtain intellisense, ensure a .d.ts file exists in the root of compilation. +Usually our scaffolding tool takes care of this. +Note: this method only works AFTER your container has been initiated
+• T extends keyof Dependencies
• key: T
a key that corresponds to a dependency registered.
+NonNullable<UnpackFunction<Partial<Dependencies>[T]>>
3.0.0
+1const client = Service('@sern/client');++Services<
+T>(…keys):IntoDependencies<T>
• T extends keyof Dependencies[]
• …keys: [...T[]]
IntoDependencies<T>
array of dependencies, in the same order of keys provided
+3.0.0 +The plural version of Service
+++single<
+T>(cb): () =>T
@PURE
+• T
+• cb
+Function
T
2.0.0. +Creates a singleton object.
+++transient<
+T>(cb): () => () =>T
@PURE
+• T
+• cb
+Function
Function
T
2.0.0 +Creates a transient object
+Module+++
optionalalias:string[]
++description:
+string
Module.description
++execute: (
+ctx,args) =>unknown
• ctx: Context
• args: Args
unknown
Module.execute
+++
optionalname:string
Module.name
++onEvent:
+ControlPlugin<any[]>[]
Module.onEvent
+++
optionaloptions:SernOptionsData[]
++plugins:
+InitPlugin<any[]>[]
Module.plugins
++type:
+Both
Module.type
Module+++
optionaldescription:string
Module.description
++execute: (
+ctx) =>unknown
• ctx: ButtonInteraction<CacheType>
unknown
Module.execute
+++
optionalname:string
Module.name
++onEvent:
+ControlPlugin<any[]>[]
Module.onEvent
++plugins:
+InitPlugin<any[]>[]
Module.plugins
++type:
+Button
Module.type
Module+++
optionaldescription:string
Module.description
++execute: (
+ctx) =>unknown
• ctx: ChannelSelectMenuInteraction<CacheType>
unknown
Module.execute
+++
optionalname:string
Module.name
++onEvent:
+ControlPlugin<any[]>[]
Module.onEvent
++plugins:
+InitPlugin<any[]>[]
Module.plugins
++type:
+ChannelSelect
Module.type
++1:
+TextCommand
++1024:
+ChannelSelectCommand
++128:
+UserSelectCommand
++16:
+ButtonCommand
++2:
+SlashCommand
++256:
+RoleSelectCommand
++3:
+BothCommand
+ ++
+ ++
+ ++
+ ++
+ ++
Module+++
optionaldescription:string
Module.description
++execute: (
+ctx) =>unknown
• ctx: MessageContextMenuCommandInteraction<CacheType>
unknown
Module.execute
+++
optionalname:string
Module.name
++onEvent:
+ControlPlugin<any[]>[]
Module.onEvent
++plugins:
+InitPlugin<any[]>[]
Module.plugins
++type:
+CtxMsg
Module.type
Module+++
optionaldescription:string
Module.description
++execute: (
+ctx) =>unknown
• ctx: UserContextMenuCommandInteraction<CacheType>
unknown
Module.execute
+++
optionalname:string
Module.name
++onEvent:
+ControlPlugin<any[]>[]
Module.onEvent
++plugins:
+InitPlugin<any[]>[]
Module.plugins
++type:
+CtxUser
Module.type
++next: () =>
+Ok<void>
Ok<void>
++stop: () =>
+Err<void>
Err<void>
• Args extends any[] = any[]
++execute: (…
+args) =>PluginResult
• …args: Args
++type:
+Control
++@sern/client: () =>
+Emitter
++@sern/emitter: () =>
+Emitter
++@sern/errors: () =>
+ErrorHandling
+++
optional@sern/logger: () =>Logging<unknown>
Logging<unknown>
++@sern/modules: () =>
+ModuleManager
ModuleManager
++ +@sern/store: () =>
+CoreModuleStore
Represents a core module store that stores IDs mapped to file paths.
+++commands:
+Map<string,Module>
src/core/contracts/module-store.ts:7
+++metadata:
+WeakMap<Module,CommandMeta>
Module• T extends keyof ClientEvents = keyof ClientEvents
+++
optionaldescription:string
Module.description
+++
optionalname:T
Module.name
++onEvent:
+ControlPlugin<any[]>[]
Module.onEvent
++plugins:
+InitPlugin<any[]>[]
Module.plugins
++type:
+Discord
Module.type
++execute(…
+args):unknown
• …args: ClientEvents[T]
unknown
Module.execute
Represents a Disposable contract. +Let dependencies implement this to dispose and cleanup.
+++dispose():
+unknown
unknown
++addListener(
+eventName,listener):this
• eventName: string | symbol
• listener: AnyFunction
this
src/core/contracts/emitter.ts:6
+++emit(
+eventName, …payload):boolean
• eventName: string | symbol
• …payload: any[]
boolean
src/core/contracts/emitter.ts:8
+++removeListener(
+eventName,listener):this
• eventName: string | symbol
• listener: AnyFunction
this
2.0.0
+++ +crash(
+err):never
• err: Error
never
src/core/contracts/error-handling.ts:9
+++updateAlive(
+error):void
A function that is called on every throw.
+• error: Error
void
++1:
+DiscordEventCommand<keyofClientEvents>
++2:
+SernEventCommand<keyofSernEventsMapping>
+ ++
Module+++
optionaldescription:string
Module.description
++emitter: keyof
+Dependencies
+++
optionalname:string
Module.name
++onEvent:
+ControlPlugin<any[]>[]
Module.onEvent
++plugins:
+InitPlugin<any[]>[]
Module.plugins
++type:
+External
Module.type
++execute(…
+args):unknown
• …args: unknown[]
unknown
Module.execute
Represents an initialization contract. +Let dependencies implement this to initiate some logic.
+++init():
+unknown
unknown
• Args extends any[] = any[]
++execute: (…
+args) =>PluginResult
• …args: Args
++type:
+Init
2.0.0
+• T = unknown
++debug(
+payload):void
• payload: LogPayload<T>
void
src/core/contracts/logging.ts:8
+++error(
+payload):void
• payload: LogPayload<T>
void
src/core/contracts/logging.ts:5
+++info(
+payload):void
• payload: LogPayload<T>
void
src/core/contracts/logging.ts:7
+++warning(
+payload):void
• payload: LogPayload<T>
void
Module+++
optionaldescription:string
Module.description
++execute: (
+ctx) =>unknown
• ctx: MentionableSelectMenuInteraction<CacheType>
unknown
Module.execute
+++
optionalname:string
Module.name
++onEvent:
+ControlPlugin<any[]>[]
Module.onEvent
++plugins:
+InitPlugin<any[]>[]
Module.plugins
++type:
+MentionableSelect
Module.type
Module+++
optionaldescription:string
Module.description
++execute: (
+ctx) =>unknown
• ctx: ModalSubmitInteraction<CacheType>
unknown
Module.execute
+++
optionalname:string
Module.name
++onEvent:
+ControlPlugin<any[]>[]
Module.onEvent
++plugins:
+InitPlugin<any[]>[]
Module.plugins
++type:
+Modal
Module.type
• Args extends any[] = any[]
++execute: (…
+args) =>PluginResult
• …args: Args
++type:
+PluginType
Module+++
optionaldescription:string
Module.description
++execute: (
+ctx) =>unknown
• ctx: RoleSelectMenuInteraction<CacheType>
unknown
Module.execute
+++
optionalname:string
Module.name
++onEvent:
+ControlPlugin<any[]>[]
Module.onEvent
++plugins:
+InitPlugin<any[]>[]
Module.plugins
++type:
+RoleSelect
Module.type
Omit<BaseApplicationCommandOptionsData, "autocomplete">++autocomplete:
+true
++command:
+AutocompleteCommand
++description:
+string
Omit.description
node_modules/discord.js/typings/index.d.ts:4711
++++
optionaldescriptionLocalizations:Partial<Record<"id"|"en-US"|"en-GB"|"bg"|"zh-CN"|"zh-TW"|"hr"|"cs"|"da"|"nl"|"fi"|"fr"|"de"|"el"|"hi"|"hu"|"it"|"ja"|"ko"|"lt"|"no"|"pl"|"pt-BR"|"ro"|"ru"|"es-ES"|"es-419"|"sv-SE"|"th"|"tr"|"uk"|"vi",null|string>>
Omit.descriptionLocalizations
node_modules/discord.js/typings/index.d.ts:4712
+++name:
+string
Omit.name
node_modules/discord.js/typings/index.d.ts:4709
++++
optionalnameLocalizations:Partial<Record<"id"|"en-US"|"en-GB"|"bg"|"zh-CN"|"zh-TW"|"hr"|"cs"|"da"|"nl"|"fi"|"fr"|"de"|"el"|"hi"|"hu"|"it"|"ja"|"ko"|"lt"|"no"|"pl"|"pt-BR"|"ro"|"ru"|"es-ES"|"es-419"|"sv-SE"|"th"|"tr"|"uk"|"vi",null|string>>
Omit.nameLocalizations
node_modules/discord.js/typings/index.d.ts:4710
++++
optionalrequired:boolean
Omit.required
node_modules/discord.js/typings/index.d.ts:4713
+++type:
+String|Integer|Number
Module• T extends keyof SernEventsMapping = keyof SernEventsMapping
+++
optionaldescription:string
Module.description
+++
optionalname:T
Module.name
++onEvent:
+ControlPlugin<any[]>[]
Module.onEvent
++plugins:
+InitPlugin<any[]>[]
Module.plugins
++type:
+Sern
Module.type
++execute(…
+args):unknown
• …args: SernEventsMapping[T]
unknown
Module.execute
APIApplicationCommandOptionBase<ApplicationCommandOptionType.Subcommand>++description:
+string
APIApplicationCommandOptionBase.description
node_modules/discord-api-types/payloads/v10/_interactions/_applicationCommands/_chatInput/base.d.ts:7
++++
optionaldescription_localizations:null|Partial<Record<"id"|"en-US"|"en-GB"|"bg"|"zh-CN"|"zh-TW"|"hr"|"cs"|"da"|"nl"|"fi"|"fr"|"de"|"el"|"hi"|"hu"|"it"|"ja"|"ko"|"lt"|"no"|"pl"|"pt-BR"|"ro"|"ru"|"es-ES"|"es-419"|"sv-SE"|"th"|"tr"|"uk"|"vi",null|string>>
APIApplicationCommandOptionBase.description_localizations
node_modules/discord-api-types/payloads/v10/_interactions/_applicationCommands/_chatInput/base.d.ts:8
+++name:
+string
APIApplicationCommandOptionBase.name
node_modules/discord-api-types/payloads/v10/_interactions/_applicationCommands/_chatInput/base.d.ts:5
++++
optionalname_localizations:null|Partial<Record<"id"|"en-US"|"en-GB"|"bg"|"zh-CN"|"zh-TW"|"hr"|"cs"|"da"|"nl"|"fi"|"fr"|"de"|"el"|"hi"|"hu"|"it"|"ja"|"ko"|"lt"|"no"|"pl"|"pt-BR"|"ro"|"ru"|"es-ES"|"es-419"|"sv-SE"|"th"|"tr"|"uk"|"vi",null|string>>
APIApplicationCommandOptionBase.name_localizations
node_modules/discord-api-types/payloads/v10/_interactions/_applicationCommands/_chatInput/base.d.ts:6
++++
optionaloptions:SernOptionsData[]
+++
optionalrequired:boolean
APIApplicationCommandOptionBase.required
node_modules/discord-api-types/payloads/v10/_interactions/_applicationCommands/_chatInput/base.d.ts:9
+++type:
+Subcommand
APIApplicationCommandOptionBase.type
BaseApplicationCommandOptionsData+++
optionalautocomplete:undefined
BaseApplicationCommandOptionsData.autocomplete
node_modules/discord.js/typings/index.d.ts:4714
+++description:
+string
BaseApplicationCommandOptionsData.description
node_modules/discord.js/typings/index.d.ts:4711
++++
optionaldescriptionLocalizations:Partial<Record<"id"|"en-US"|"en-GB"|"bg"|"zh-CN"|"zh-TW"|"hr"|"cs"|"da"|"nl"|"fi"|"fr"|"de"|"el"|"hi"|"hu"|"it"|"ja"|"ko"|"lt"|"no"|"pl"|"pt-BR"|"ro"|"ru"|"es-ES"|"es-419"|"sv-SE"|"th"|"tr"|"uk"|"vi",null|string>>
BaseApplicationCommandOptionsData.descriptionLocalizations
node_modules/discord.js/typings/index.d.ts:4712
+++name:
+string
BaseApplicationCommandOptionsData.name
node_modules/discord.js/typings/index.d.ts:4709
++++
optionalnameLocalizations:Partial<Record<"id"|"en-US"|"en-GB"|"bg"|"zh-CN"|"zh-TW"|"hr"|"cs"|"da"|"nl"|"fi"|"fr"|"de"|"el"|"hi"|"hu"|"it"|"ja"|"ko"|"lt"|"no"|"pl"|"pt-BR"|"ro"|"ru"|"es-ES"|"es-419"|"sv-SE"|"th"|"tr"|"uk"|"vi",null|string>>
BaseApplicationCommandOptionsData.nameLocalizations
node_modules/discord.js/typings/index.d.ts:4710
++++
optionaloptions:SernSubCommandData[]
+++
optionalrequired:boolean
BaseApplicationCommandOptionsData.required
node_modules/discord.js/typings/index.d.ts:4713
+++type:
+SubcommandGroup
Module++description:
+string
Module.description
++execute: (
+ctx,args) =>unknown
• ctx: Context
• args: ["slash", SlashOptions]
unknown
Module.execute
+++
optionalname:string
Module.name
++onEvent:
+ControlPlugin<any[]>[]
Module.onEvent
+++
optionaloptions:SernOptionsData[]
++plugins:
+InitPlugin<any[]>[]
Module.plugins
++type:
+Slash
Module.type
Module+++
optionaldescription:string
Module.description
++execute: (
+ctx) =>unknown
• ctx: StringSelectMenuInteraction<CacheType>
unknown
Module.execute
+++
optionalname:string
Module.name
++onEvent:
+ControlPlugin<any[]>[]
Module.onEvent
++plugins:
+InitPlugin<any[]>[]
Module.plugins
++type:
+StringSelect
Module.type
Module+++
optionalalias:string[]
+++
optionaldescription:string
Module.description
++execute: (
+ctx,args) =>unknown
• ctx: Context
• args: ["text", string[]]
unknown
Module.execute
+++
optionalname:string
Module.name
++onEvent:
+ControlPlugin<any[]>[]
Module.onEvent
++plugins:
+InitPlugin<any[]>[]
Module.plugins
++type:
+Text
Module.type
Module+++
optionaldescription:string
Module.description
++execute: (
+ctx) =>unknown
• ctx: UserSelectMenuInteraction<CacheType>
unknown
Module.execute
+++
optionalname:string
Module.name
++onEvent:
+ControlPlugin<any[]>[]
Module.onEvent
++plugins:
+InitPlugin<any[]>[]
Module.plugins
++type:
+UserSelect
Module.type
++commands:
+string
+++
optionalcontainerConfig:object
++get: (…
+keys) =>unknown[]
• …keys: keyof Dependencies[]
unknown[]
+++
optionaldefaultPrefix:string
+++
optionalevents:string
+++
optionalmode:string
Overload to enable mode in case developer does not use a .env file.
+ +++module<
+T>(conf):Config<T>
A small wrapper to provide type inference. +Create a Presence module which MUST be put in a file called presence.(language-extension) +adjacent to the file where Sern.init is CALLED.
+• T extends keyof Dependencies[]
• conf: Config<T>
Config<T>
++of(
+root):object
Create a Presence body which can be either:
+• root: Omit<Result, "repeat" | "onRepeat">
object
++once: () =>
+Omit<Result,"repeat"|"onRepeat">
1Presence2 .of({3 activities: [4 { name: "Chilling out" }5 ]6 })7 .once() // Sets the presence once, with what's provided in '.of()'Omit<Result, "repeat" | "onRepeat">
++repeated: (
+onRepeat,repeat) =>object
1Presence2 .of({3 activities: [{ name: "deez nuts" }]4 }) //starts the presence with "deez nuts".5 .repeated(prev => {6 return {7 afk: true,8 activities: prev.activities?.map(s => ({ ...s, name: s.name+"s" }))9 };10 }, 10000)) //every 10 s, the callback sets the presence to the returned one.• onRepeat: PresenceReduce
• repeat: number | [Emitter, string]
object
+++
optionalactivities:ActivitiesOptions[]
+++
optionalafk:boolean
++onRepeat:
+PresenceReduce
++repeat:
+number| [Emitter,string]
+++
optionalshardId:number[]
+++
optionalstatus:Status
+++
optionalactivities:ActivitiesOptions[]
+++
optionalafk:boolean
+++
optionalonRepeat: (previous) =>Result
• previous: Result
+++
optionalrepeat:number| [Emitter,string]
+++
optionalshardId:number[]
+++
optionalstatus:Status
++Config<
+T>:object
• T extends keyof Dependencies[]
++execute: (…
+v) =>Result
• …v: IntoDependencies<T>
+++
optionalinject: [...T]
++init(
+maybeWrapper):void
• maybeWrapper: Wrapper | "file"
void
1.0.0
+1Sern.init({2 commands: 'dist/commands',3 events: 'dist/events',4})++AnyCommandPlugin:
+ControlPlugin|InitPlugin<[InitArgs<Processed<CommandModule>>]>
++AnyEventPlugin:
+ControlPlugin|InitPlugin<[InitArgs<Processed<EventModule>>]>
++Args:
+ParseType<object>
++slash:
+SlashOptions
++text:
+string[]
++CommandModule:
+TextCommand|SlashCommand|BothCommand|ContextMenuUser|ContextMenuMsg|ButtonCommand|StringSelectCommand|MentionableSelectCommand|UserSelectCommand|ChannelSelectCommand|RoleSelectCommand|ModalSubmitCommand
++EventModule:
+DiscordEventCommand|SernEventCommand|ExternalEventCommand
++Initializable<
+T>:T
Type to annotate that something is initializable. +If T has an init method, this will be called.
+• T extends Init
++LogPayload<
+T>:object
• T = unknown
++message:
+T
++SernOptionsData:
+SernSubCommandData|SernSubCommandGroupData|APIApplicationCommandBasicOption|SernAutocompleteData
Type that replaces autocomplete with SernAutocompleteData
+++Singleton<
+T>: () =>T
Type to annotate that something is a singleton. +T is created once and lazily.
+• T
+T
++SlashOptions:
+Omit<CommandInteractionOptionResolver,"getMessage"|"getFocused">
++Transient<
+T>: () => () =>T
Type to annotate that something is transient. +Every time this is called, a new object is created
+• T
+Function
T
+++
constcontroller:object
1.0.0 +The object passed into every plugin to control a command’s behavior
+++next: () =>
+OkImpl<void> =ok
OkImpl<void>
++stop: () =>
+ErrImpl<void> =err
ErrImpl<void>
["'])(?.*?)\1/,a=/\{(? [\d,-]+)\}/,r={js:{start:"\\/\\/",end:""},jsBlock:{start:"\\/\\*",end:"\\*\\/"},jsx:{start:"\\{\\s*\\/\\*",end:"\\*\\/\\s*\\}"},bash:{start:"#",end:""},html:{start:"\x3c!--",end:"--\x3e"},lua:{start:"--",end:""},wasm:{start:"\\;\\;",end:""},tex:{start:"%",end:""}};function l(e,t){const n=e.map((e=>{const{start:n,end:s}=r[e];return`(?:${n}\\s*(${t.flatMap((e=>[e.line,e.block?.start,e.block?.end].filter(Boolean))).join("|")})\\s*${s})`})).join("|");return new RegExp(`^\\s*(?:${n})\\s*$`)}function i(e){return e?.match(c)?.groups.title??""}function u(e){return Boolean(e?.includes("showLineNumbers"))}function d(e){const t=e.split(" ").find((e=>e.startsWith("language-")));return t?.replace(/language-/,"")}function m(e,t){let n=e.replace(/\n$/,"");const{language:s,magicComments:c,metastring:i}=t;if(i&&a.test(i)){const e=i.match(a).groups.range;if(0===c.length)throw new Error(`A highlight range has been given in code block's metastring (\`\`\` ${i}), but no magic comment config is available. Docusaurus applies the first magic comment entry's className for metastring ranges.`);const t=c[0].className,s=o()(e).filter((e=>e>0)).map((e=>[e-1,[t]]));return{lineClassNames:Object.fromEntries(s),code:n}}if(void 0===s)return{lineClassNames:{},code:n};const u=function(e,t){switch(e){case"js":case"javascript":case"ts":case"typescript":return l(["js","jsBlock"],t);case"jsx":case"tsx":return l(["js","jsBlock","jsx"],t);case"html":return l(["js","jsBlock","html"],t);case"python":case"py":case"bash":return l(["bash"],t);case"markdown":case"md":return l(["html","jsx","bash"],t);case"tex":case"latex":case"matlab":return l(["tex"],t);case"lua":case"haskell":case"sql":return l(["lua"],t);case"wasm":return l(["wasm"],t);default:return l(Object.keys(r).filter((e=>!["lua","wasm","tex","latex","matlab"].includes(e))),t)}}(s,c),d=n.split("\n"),m=Object.fromEntries(c.map((e=>[e.className,{start:0,range:""}]))),p=Object.fromEntries(c.filter((e=>e.line)).map((e=>{let{className:t,line:n}=e;return[n,t]}))),b=Object.fromEntries(c.filter((e=>e.block)).map((e=>{let{className:t,block:n}=e;return[n.start,t]}))),h=Object.fromEntries(c.filter((e=>e.block)).map((e=>{let{className:t,block:n}=e;return[n.end,t]})));for(let o=0;o void 0!==e));p[t]?m[p[t]].range+=`${o},`:b[t]?m[b[t]].start=o:h[t]&&(m[h[t]].range+=`${m[h[t]].start}-${o-1},`),d.splice(o,1)}n=d.join("\n");const f={};return Object.entries(m).forEach((e=>{let[t,{range:n}]=e;o()(n).forEach((e=>{f[e]??=[],f[e].push(t)}))})),{lineClassNames:f,code:n}}function p(e){const t={color:"--prism-color",backgroundColor:"--prism-background-color"},n={};return Object.entries(e.plain).forEach((e=>{let[s,o]=e;const c=t[s];c&&"string"==typeof o&&(n[c]=o)})),n}},7562:(e,t,n)=>{"use strict";n.d(t,{A:()=>s});const s={codeBlockContent:"codeBlockContent_biex",codeBlockTitle:"codeBlockTitle_Ktv7",codeBlock:"codeBlock_bY9V",codeBlockStandalone:"codeBlockStandalone_MEMb",codeBlockLines:"codeBlockLines_e6Vv",codeBlockLinesWithNumbering:"codeBlockLinesWithNumbering_o6Pm",buttonGroup:"buttonGroup__atx"}},8426:(e,t)=>{function n(e){let t,n=[];for(let s of e.split(",").map((e=>e.trim())))if(/^-?\d+$/.test(s))n.push(parseInt(s,10));else if(t=s.match(/^(-?\d+)(-|\.\.\.?|\u2025|\u2026|\u22EF)(-?\d+)$/)){let[e,s,o,c]=t;if(s&&c){s=parseInt(s),c=parseInt(c);const e=s {r.r(n),r.d(n,{assets:()=>o,contentTitle:()=>c,default:()=>h,frontMatter:()=>d,metadata:()=>i,toc:()=>l});var s=r(4848),t=r(8453);const d={id:"CommandError",title:"Namespace: CommandError",sidebar_label:"CommandError",sidebar_position:0,custom_edit_url:null},c=void 0,i={id:"api/namespaces/CommandError",title:"Namespace: CommandError",description:"Interfaces",source:"@site/docs/api/namespaces/CommandError.md",sourceDirName:"api/namespaces",slug:"/api/namespaces/CommandError",permalink:"/docs/api/namespaces/CommandError",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"CommandError",title:"Namespace: CommandError",sidebar_label:"CommandError",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"Exports",permalink:"/docs/api/modules"},next:{title:"Presence",permalink:"/docs/api/namespaces/Presence"}},o={},l=[{value:"Interfaces",id:"interfaces",level:2},{value:"Functions",id:"functions",level:2},{value:"of",id:"of",level:3},{value:"Returns",id:"returns",level:4},{value:"Defined in",id:"defined-in",level:4}];function a(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,t.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.h2,{id:"interfaces",children:"Interfaces"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/docs/api/interfaces/CommandError.Response",children:"Response"})}),"\n"]}),"\n",(0,s.jsx)(n.h2,{id:"functions",children:"Functions"}),"\n",(0,s.jsx)(n.h3,{id:"of",children:"of"}),"\n",(0,s.jsxs)(n.p,{children:["\u25b8 ",(0,s.jsx)(n.strong,{children:"of"}),"(): ",(0,s.jsx)(n.code,{children:"Object"})]}),"\n",(0,s.jsx)(n.h4,{id:"returns",children:"Returns"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.code,{children:"Object"})}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,s.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,s.jsxs)(n.tbody,{children:[(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{style:{textAlign:"left"},children:(0,s.jsx)(n.code,{children:"log"})}),(0,s.jsxs)(n.td,{style:{textAlign:"left"},children:[" (",(0,s.jsx)(n.code,{children:"type"}),": keyof ",(0,s.jsx)(n.a,{href:"/docs/api/interfaces/Logging",children:(0,s.jsx)(n.code,{children:"Logging"})}),"<",(0,s.jsx)(n.code,{children:"unknown"}),">, ",(0,s.jsx)(n.code,{children:"message"}),": ",(0,s.jsx)(n.code,{children:"T"}),") => ",(0,s.jsx)(n.code,{children:"Record"}),"<",(0,s.jsx)(n.code,{children:"PropertyKey"}),", ",(0,s.jsx)(n.code,{children:"unknown"}),">"]})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{style:{textAlign:"left"},children:(0,s.jsx)(n.code,{children:"reply"})}),(0,s.jsxs)(n.td,{style:{textAlign:"left"},children:["(",(0,s.jsx)(n.code,{children:"bodyContent"}),": ",(0,s.jsx)(n.code,{children:"ReplyOptions"}),") => ",(0,s.jsx)(n.code,{children:"Record"}),"<",(0,s.jsx)(n.code,{children:"PropertyKey"}),", ",(0,s.jsx)(n.code,{children:"unknown"}),">"]})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{style:{textAlign:"left"},children:(0,s.jsx)(n.code,{children:"status"})}),(0,s.jsxs)(n.td,{style:{textAlign:"left"},children:["(",(0,s.jsx)(n.code,{children:"p"}),": ",(0,s.jsx)(n.code,{children:'"fail"'})," | ",(0,s.jsx)(n.code,{children:'"continue"'}),") => ",(0,s.jsx)(n.code,{children:"Record"}),"<",(0,s.jsx)(n.code,{children:"PropertyKey"}),", ",(0,s.jsx)(n.code,{children:"unknown"}),">"]})]})]})]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/504cdee/src/core/structures/command-error.ts#L10",children:"src/core/structures/command-error.ts:10"})})]})}function h(e={}){const{wrapper:n}={...(0,t.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(a,{...e})}):a(e)}},8453:(e,n,r)=>{r.d(n,{R:()=>c,x:()=>i});var s=r(6540);const t={},d=s.createContext(t);function c(e){const n=s.useContext(d);return s.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function i(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(t):e.components||t:c(e.components),s.createElement(d.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/79e7cc44.ec89a63b.js b/assets/js/79e7cc44.ec89a63b.js deleted file mode 100644 index 8b5f52ad3..000000000 --- a/assets/js/79e7cc44.ec89a63b.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[3617],{7213:(e,n,i)=>{i.r(n),i.d(n,{assets:()=>c,contentTitle:()=>s,default:()=>o,frontMatter:()=>d,metadata:()=>t,toc:()=>h});var r=i(4848),l=i(8453);const d={id:"SernEventPlugin",title:"Interface: SernEventPlugin ",sidebar_label:"SernEventPlugin",sidebar_position:0,custom_edit_url:null},s=void 0,t={id:"api/interfaces/SernEventPlugin",title:"Interface: SernEventPlugin ",description:"Type parameters",source:"@site/docs/api/interfaces/SernEventPlugin.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/SernEventPlugin",permalink:"/docs/api/interfaces/SernEventPlugin",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"SernEventPlugin",title:"Interface: SernEventPlugin ",sidebar_label:"SernEventPlugin",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"SernEventCommand",permalink:"/docs/api/interfaces/SernEventCommand"},next:{title:"SernEventsMapping",permalink:"/docs/api/interfaces/SernEventsMapping"}},c={},h=[{value:"Type parameters",id:"type-parameters",level:2},{value:"Hierarchy",id:"hierarchy",level:2},{value:"Properties",id:"properties",level:2},{value:"description",id:"description",level:3},{value:"Inherited from",id:"inherited-from",level:4},{value:"Defined in",id:"defined-in",level:4},{value:"execute",id:"execute",level:3},{value:"Type declaration",id:"type-declaration",level:4},{value:"Parameters",id:"parameters",level:5},{value:"Returns",id:"returns",level:5},{value:"Defined in",id:"defined-in-1",level:4},{value:"name",id:"name",level:3},{value:"Overrides",id:"overrides",level:4},{value:"Defined in",id:"defined-in-2",level:4},{value:"type",id:"type",level:3},{value:"Overrides",id:"overrides-1",level:4},{value:"Defined in",id:"defined-in-3",level:4}];function a(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",h5:"h5",hr:"hr",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,l.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(n.h2,{id:"type-parameters",children:"Type parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"T"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["extends keyof ",(0,r.jsx)(n.a,{href:"/docs/api/modules#serneventsmapping",children:(0,r.jsx)(n.code,{children:"SernEventsMapping"})})," = keyof ",(0,r.jsx)(n.a,{href:"/docs/api/modules#serneventsmapping",children:(0,r.jsx)(n.code,{children:"SernEventsMapping"})})]})]})})]}),"\n",(0,r.jsx)(n.h2,{id:"hierarchy",children:"Hierarchy"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:(0,r.jsx)(n.code,{children:"Plugin"})})}),"\n",(0,r.jsxs)(n.p,{children:["\u21b3 ",(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"SernEventPlugin"})})]}),"\n"]}),"\n"]}),"\n",(0,r.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,r.jsx)(n.h3,{id:"description",children:"description"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"description"}),": ",(0,r.jsx)(n.code,{children:"string"})]}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Deprecated"})})}),"\n",(0,r.jsx)(n.p,{children:"will be removed in the next update"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from",children:"Inherited from"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:"Plugin"}),".",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin#description",children:"description"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L33",children:"src/handler/plugins/plugin.ts:33"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"execute",children:"execute"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"execute"}),": (",(0,r.jsx)(n.code,{children:"args"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/modules#serneventsmapping",children:(0,r.jsx)(n.code,{children:"SernEventsMapping"})}),"[",(0,r.jsx)(n.code,{children:"T"}),"], ",(0,r.jsx)(n.code,{children:"controller"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Controller",children:(0,r.jsx)(n.code,{children:"Controller"})}),") => ",(0,r.jsx)(n.code,{children:"Awaitable"}),"<",(0,r.jsx)(n.code,{children:"Result"}),"<",(0,r.jsx)(n.code,{children:"void"}),", ",(0,r.jsx)(n.code,{children:"void"}),">>"]}),"\n",(0,r.jsx)(n.h4,{id:"type-declaration",children:"Type declaration"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 (",(0,r.jsx)(n.code,{children:"args"}),", ",(0,r.jsx)(n.code,{children:"controller"}),"): ",(0,r.jsx)(n.code,{children:"Awaitable"}),"<",(0,r.jsx)(n.code,{children:"Result"}),"<",(0,r.jsx)(n.code,{children:"void"}),", ",(0,r.jsx)(n.code,{children:"void"}),">>"]}),"\n",(0,r.jsx)(n.h5,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"args"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.a,{href:"/docs/api/modules#serneventsmapping",children:(0,r.jsx)(n.code,{children:"SernEventsMapping"})}),"[",(0,r.jsx)(n.code,{children:"T"}),"]"]})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"controller"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Controller",children:(0,r.jsx)(n.code,{children:"Controller"})})})]})]})]}),"\n",(0,r.jsx)(n.h5,{id:"returns",children:"Returns"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.code,{children:"Awaitable"}),"<",(0,r.jsx)(n.code,{children:"Result"}),"<",(0,r.jsx)(n.code,{children:"void"}),", ",(0,r.jsx)(n.code,{children:"void"}),">>"]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L91",children:"src/handler/plugins/plugin.ts:91"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"name",children:"name"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"name"}),": ",(0,r.jsx)(n.code,{children:"T"})]}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Deprecated"})})}),"\n",(0,r.jsx)(n.p,{children:"will be removed in the next update"}),"\n",(0,r.jsx)(n.h4,{id:"overrides",children:"Overrides"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:"Plugin"}),".",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin#name",children:"name"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L89",children:"src/handler/plugins/plugin.ts:89"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"type",children:"type"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"type"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/enums/PluginType#event",children:(0,r.jsx)(n.code,{children:"Event"})})]}),"\n",(0,r.jsx)(n.h4,{id:"overrides-1",children:"Overrides"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:"Plugin"}),".",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin#type",children:"type"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L90",children:"src/handler/plugins/plugin.ts:90"})})]})}function o(e={}){const{wrapper:n}={...(0,l.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(a,{...e})}):a(e)}},8453:(e,n,i)=>{i.d(n,{R:()=>s,x:()=>t});var r=i(6540);const l={},d=r.createContext(l);function s(e){const n=r.useContext(d);return r.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function t(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(l):e.components||l:s(e.components),r.createElement(d.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/7b758ddf.bebefb7e.js b/assets/js/7b758ddf.bebefb7e.js deleted file mode 100644 index f0b915e3f..000000000 --- a/assets/js/7b758ddf.bebefb7e.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[5938],{6942:(e,t,n)=>{n.r(t),n.d(t,{assets:()=>r,contentTitle:()=>a,default:()=>d,frontMatter:()=>s,metadata:()=>c,toc:()=>l});var o=n(4848),i=n(8453);const s={sidebar_position:7},a="Autocomplete",c={id:"guide/walkthrough/autocomplete",title:"Autocomplete",description:"Autocomplete is a special interaction where it can happen on multiple options on a single command. We've handled this with a simple",source:"@site/docs/guide/walkthrough/autocomplete.md",sourceDirName:"guide/walkthrough",slug:"/guide/walkthrough/autocomplete",permalink:"/docs/guide/walkthrough/autocomplete",draft:!1,unlisted:!1,editUrl:"https://github.com/sern-handler/website/edit/main/docs/guide/walkthrough/autocomplete.md",tags:[],version:"current",sidebarPosition:7,frontMatter:{sidebar_position:7},sidebar:"tutorialSidebar",previous:{title:"Services",permalink:"/docs/guide/walkthrough/services"},next:{title:"Dependency Injection",permalink:"/docs/guide/walkthrough/dependency-injection"}},r={},l=[{value:"Example",id:"example",level:2}];function p(e){const t={code:"code",h1:"h1",h2:"h2",p:"p",pre:"pre",...(0,i.R)(),...e.components};return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(t.h1,{id:"autocomplete",children:"Autocomplete"}),"\n",(0,o.jsx)(t.p,{children:"Autocomplete is a special interaction where it can happen on multiple options on a single command. We've handled this with a simple\ntree search algorithm in a nested options tree."}),"\n",(0,o.jsx)(t.h2,{id:"example",children:"Example"}),"\n",(0,o.jsx)(t.pre,{children:(0,o.jsx)(t.code,{className:"language-ts",metastring:'title="src/commands/cheese.ts" {11-18}',children:"export default commandModule({ \n type: CommandType.Slash,\n description: \"show me cheese\",\n options: [\n { \n name: \"list\",\n\t type: ApplicationCommandOptionType.String,\n\t description: \"pick a cheese to show\",\n\t required: true,\n\t autocomplete: true,\n\t command: {\n onEvent: [],\n execute: (ctx) => {\n const focus = ctx.options.getFocused();\n ctx.respond(['gouda', 'parmesan', 'harvati']\n .map((cheese) => ({ name: cheese, value: cheese })));\n\t }\n\t}\n\t}\n ],\n execute: (ctx, [, args]) => {\n const cheese = args.getString('list', true); \n ctx.reply('selected cheese');\n }\n})\n\n\n"})}),"\n",(0,o.jsx)(t.p,{children:"Sern will handle autocomplete interactions at arbitrary depths and subcommand levels."})]})}function d(e={}){const{wrapper:t}={...(0,i.R)(),...e.components};return t?(0,o.jsx)(t,{...e,children:(0,o.jsx)(p,{...e})}):p(e)}},8453:(e,t,n)=>{n.d(t,{R:()=>a,x:()=>c});var o=n(6540);const i={},s=o.createContext(i);function a(e){const t=o.useContext(s);return o.useMemo((function(){return"function"==typeof e?e(t):{...t,...e}}),[t,e])}function c(e){let t;return t=e.disableParentContext?"function"==typeof e.components?e.components(i):e.components||i:a(e.components),o.createElement(s.Provider,{value:t},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/7c2ff145.d5069700.js b/assets/js/7c2ff145.d5069700.js deleted file mode 100644 index 50e8e0d39..000000000 --- a/assets/js/7c2ff145.d5069700.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[9143],{2945:e=>{e.exports=JSON.parse('{"name":"docusaurus-plugin-content-blog","id":"default"}')}}]); \ No newline at end of file diff --git a/assets/js/7cd974c8.f09c829b.js b/assets/js/7cd974c8.f09c829b.js deleted file mode 100644 index fc2c66257..000000000 --- a/assets/js/7cd974c8.f09c829b.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[8976],{9905:(e,n,i)=>{i.r(n),i.d(n,{assets:()=>c,contentTitle:()=>t,default:()=>a,frontMatter:()=>s,metadata:()=>l,toc:()=>o});var r=i(4848),d=i(8453);const s={id:"ContextMenuMsg",title:"Interface: ContextMenuMsg",sidebar_label:"ContextMenuMsg",sidebar_position:0,custom_edit_url:null},t=void 0,l={id:"api/interfaces/ContextMenuMsg",title:"Interface: ContextMenuMsg",description:"Hierarchy",source:"@site/docs/api/interfaces/ContextMenuMsg.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/ContextMenuMsg",permalink:"/docs/api/interfaces/ContextMenuMsg",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"ContextMenuMsg",title:"Interface: ContextMenuMsg",sidebar_label:"ContextMenuMsg",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"CommandPlugin",permalink:"/docs/api/interfaces/CommandPlugin"},next:{title:"ContextMenuUser",permalink:"/docs/api/interfaces/ContextMenuUser"}},c={},o=[{value:"Hierarchy",id:"hierarchy",level:2},{value:"Properties",id:"properties",level:2},{value:"description",id:"description",level:3},{value:"Inherited from",id:"inherited-from",level:4},{value:"Defined in",id:"defined-in",level:4},{value:"execute",id:"execute",level:3},{value:"Type declaration",id:"type-declaration",level:4},{value:"Parameters",id:"parameters",level:5},{value:"Returns",id:"returns",level:5},{value:"Overrides",id:"overrides",level:4},{value:"Defined in",id:"defined-in-1",level:4},{value:"name",id:"name",level:3},{value:"Inherited from",id:"inherited-from-1",level:4},{value:"Defined in",id:"defined-in-2",level:4},{value:"onEvent",id:"onevent",level:3},{value:"Inherited from",id:"inherited-from-2",level:4},{value:"Defined in",id:"defined-in-3",level:4},{value:"plugins",id:"plugins",level:3},{value:"Inherited from",id:"inherited-from-3",level:4},{value:"Defined in",id:"defined-in-4",level:4},{value:"type",id:"type",level:3},{value:"Overrides",id:"overrides-1",level:4},{value:"Defined in",id:"defined-in-5",level:4}];function h(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",h5:"h5",hr:"hr",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,d.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(n.h2,{id:"hierarchy",children:"Hierarchy"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"Module"})}),"\n",(0,r.jsxs)(n.p,{children:["\u21b3 ",(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"ContextMenuMsg"})})]}),"\n"]}),"\n"]}),"\n",(0,r.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,r.jsx)(n.h3,{id:"description",children:"description"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"description"}),": ",(0,r.jsx)(n.code,{children:"string"})]}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"Module.description"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L36",children:"src/types/core-modules.ts:36"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"execute",children:"execute"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"execute"}),": (",(0,r.jsx)(n.code,{children:"ctx"}),": ",(0,r.jsx)(n.code,{children:"MessageContextMenuCommandInteraction"}),"<",(0,r.jsx)(n.code,{children:"CacheType"}),">) => ",(0,r.jsx)(n.code,{children:"unknown"})]}),"\n",(0,r.jsx)(n.h4,{id:"type-declaration",children:"Type declaration"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 (",(0,r.jsx)(n.code,{children:"ctx"}),"): ",(0,r.jsx)(n.code,{children:"unknown"})]}),"\n",(0,r.jsx)(n.h5,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"ctx"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"MessageContextMenuCommandInteraction"}),"<",(0,r.jsx)(n.code,{children:"CacheType"}),">"]})]})})]}),"\n",(0,r.jsx)(n.h5,{id:"returns",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"unknown"})}),"\n",(0,r.jsx)(n.h4,{id:"overrides",children:"Overrides"}),"\n",(0,r.jsx)(n.p,{children:"Module.execute"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L60",children:"src/types/core-modules.ts:60"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"name",children:"name"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"name"}),": ",(0,r.jsx)(n.code,{children:"string"})]}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-1",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"Module.name"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L33",children:"src/types/core-modules.ts:33"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"onevent",children:"onEvent"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"onEvent"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/ControlPlugin",children:(0,r.jsx)(n.code,{children:"ControlPlugin"})}),"<",(0,r.jsx)(n.code,{children:"any"}),"[]>[]"]}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-2",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"Module.onEvent"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L34",children:"src/types/core-modules.ts:34"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"plugins",children:"plugins"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"plugins"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/InitPlugin",children:(0,r.jsx)(n.code,{children:"InitPlugin"})}),"<",(0,r.jsx)(n.code,{children:"any"}),"[]>[]"]}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-3",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"Module.plugins"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-4",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L35",children:"src/types/core-modules.ts:35"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"type",children:"type"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"type"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/enums/CommandType#ctxmsg",children:(0,r.jsx)(n.code,{children:"CtxMsg"})})]}),"\n",(0,r.jsx)(n.h4,{id:"overrides-1",children:"Overrides"}),"\n",(0,r.jsx)(n.p,{children:"Module.type"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-5",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L59",children:"src/types/core-modules.ts:59"})})]})}function a(e={}){const{wrapper:n}={...(0,d.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(h,{...e})}):h(e)}},8453:(e,n,i)=>{i.d(n,{R:()=>t,x:()=>l});var r=i(6540);const d={},s=r.createContext(d);function t(e){const n=r.useContext(s);return r.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function l(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(d):e.components||d:t(e.components),r.createElement(s.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/7e205c4a.468206c4.js b/assets/js/7e205c4a.468206c4.js deleted file mode 100644 index 2a1bbbd2e..000000000 --- a/assets/js/7e205c4a.468206c4.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[2212],{2868:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>c,contentTitle:()=>l,default:()=>x,frontMatter:()=>i,metadata:()=>d,toc:()=>h});var r=t(4848),s=t(8453);const i={id:"SernEmitter",title:"Class: SernEmitter",sidebar_label:"SernEmitter",sidebar_position:0,custom_edit_url:null},l=void 0,d={id:"api/classes/SernEmitter",title:"Class: SernEmitter",description:"Since",source:"@site/docs/api/classes/SernEmitter.md",sourceDirName:"api/classes",slug:"/api/classes/SernEmitter",permalink:"/docs/api/classes/SernEmitter",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"SernEmitter",title:"Class: SernEmitter",sidebar_label:"SernEmitter",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"ModuleStore",permalink:"/docs/api/classes/ModuleStore"},next:{title:"AutocompleteCommand",permalink:"/docs/api/interfaces/AutocompleteCommand"}},c={},h=[{value:"Hierarchy",id:"hierarchy",level:2},{value:"Constructors",id:"constructors",level:2},{value:"constructor",id:"constructor",level:3},{value:"Returns",id:"returns",level:4},{value:"Overrides",id:"overrides",level:4},{value:"Defined in",id:"defined-in",level:4},{value:"Properties",id:"properties",level:2},{value:"captureRejectionSymbol",id:"capturerejectionsymbol",level:3},{value:"Inherited from",id:"inherited-from",level:4},{value:"Defined in",id:"defined-in-1",level:4},{value:"captureRejections",id:"capturerejections",level:3},{value:"Inherited from",id:"inherited-from-1",level:4},{value:"Defined in",id:"defined-in-2",level:4},{value:"defaultMaxListeners",id:"defaultmaxlisteners",level:3},{value:"Inherited from",id:"inherited-from-2",level:4},{value:"Defined in",id:"defined-in-3",level:4},{value:"errorMonitor",id:"errormonitor",level:3},{value:"Inherited from",id:"inherited-from-3",level:4},{value:"Defined in",id:"defined-in-4",level:4},{value:"Methods",id:"methods",level:2},{value:"addListener",id:"addlistener",level:3},{value:"Parameters",id:"parameters",level:4},{value:"Returns",id:"returns-1",level:4},{value:"Inherited from",id:"inherited-from-4",level:4},{value:"Defined in",id:"defined-in-5",level:4},{value:"emit",id:"emit",level:3},{value:"Type parameters",id:"type-parameters",level:4},{value:"Parameters",id:"parameters-1",level:4},{value:"Returns",id:"returns-2",level:4},{value:"Overrides",id:"overrides-1",level:4},{value:"Defined in",id:"defined-in-6",level:4},{value:"eventNames",id:"eventnames",level:3},{value:"Returns",id:"returns-3",level:4},{value:"Inherited from",id:"inherited-from-5",level:4},{value:"Defined in",id:"defined-in-7",level:4},{value:"getMaxListeners",id:"getmaxlisteners",level:3},{value:"Returns",id:"returns-4",level:4},{value:"Inherited from",id:"inherited-from-6",level:4},{value:"Defined in",id:"defined-in-8",level:4},{value:"listenerCount",id:"listenercount",level:3},{value:"Parameters",id:"parameters-2",level:4},{value:"Returns",id:"returns-5",level:4},{value:"Inherited from",id:"inherited-from-7",level:4},{value:"Defined in",id:"defined-in-9",level:4},{value:"listeners",id:"listeners",level:3},{value:"Parameters",id:"parameters-3",level:4},{value:"Returns",id:"returns-6",level:4},{value:"Inherited from",id:"inherited-from-8",level:4},{value:"Defined in",id:"defined-in-10",level:4},{value:"off",id:"off",level:3},{value:"Parameters",id:"parameters-4",level:4},{value:"Returns",id:"returns-7",level:4},{value:"Inherited from",id:"inherited-from-9",level:4},{value:"Defined in",id:"defined-in-11",level:4},{value:"on",id:"on",level:3},{value:"Type parameters",id:"type-parameters-1",level:4},{value:"Parameters",id:"parameters-5",level:4},{value:"Returns",id:"returns-8",level:4},{value:"Overrides",id:"overrides-2",level:4},{value:"Defined in",id:"defined-in-12",level:4},{value:"once",id:"once",level:3},{value:"Type parameters",id:"type-parameters-2",level:4},{value:"Parameters",id:"parameters-6",level:4},{value:"Returns",id:"returns-9",level:4},{value:"Overrides",id:"overrides-3",level:4},{value:"Defined in",id:"defined-in-13",level:4},{value:"prependListener",id:"prependlistener",level:3},{value:"Parameters",id:"parameters-7",level:4},{value:"Returns",id:"returns-10",level:4},{value:"Inherited from",id:"inherited-from-10",level:4},{value:"Defined in",id:"defined-in-14",level:4},{value:"prependOnceListener",id:"prependoncelistener",level:3},{value:"Parameters",id:"parameters-8",level:4},{value:"Returns",id:"returns-11",level:4},{value:"Inherited from",id:"inherited-from-11",level:4},{value:"Defined in",id:"defined-in-15",level:4},{value:"rawListeners",id:"rawlisteners",level:3},{value:"Parameters",id:"parameters-9",level:4},{value:"Returns",id:"returns-12",level:4},{value:"Inherited from",id:"inherited-from-12",level:4},{value:"Defined in",id:"defined-in-16",level:4},{value:"removeAllListeners",id:"removealllisteners",level:3},{value:"Parameters",id:"parameters-10",level:4},{value:"Returns",id:"returns-13",level:4},{value:"Inherited from",id:"inherited-from-13",level:4},{value:"Defined in",id:"defined-in-17",level:4},{value:"removeListener",id:"removelistener",level:3},{value:"Parameters",id:"parameters-11",level:4},{value:"Returns",id:"returns-14",level:4},{value:"Inherited from",id:"inherited-from-14",level:4},{value:"Defined in",id:"defined-in-18",level:4},{value:"setMaxListeners",id:"setmaxlisteners",level:3},{value:"Parameters",id:"parameters-12",level:4},{value:"Returns",id:"returns-15",level:4},{value:"Inherited from",id:"inherited-from-15",level:4},{value:"Defined in",id:"defined-in-19",level:4},{value:"failure",id:"failure",level:3},{value:"Parameters",id:"parameters-13",level:4},{value:"Returns",id:"returns-16",level:4},{value:"Defined in",id:"defined-in-20",level:4},{value:"getEventListeners",id:"geteventlisteners",level:3},{value:"Parameters",id:"parameters-14",level:4},{value:"Returns",id:"returns-17",level:4},{value:"Inherited from",id:"inherited-from-16",level:4},{value:"Defined in",id:"defined-in-21",level:4},{value:"getMaxListeners",id:"getmaxlisteners-1",level:3},{value:"Parameters",id:"parameters-15",level:4},{value:"Returns",id:"returns-18",level:4},{value:"Inherited from",id:"inherited-from-17",level:4},{value:"Defined in",id:"defined-in-22",level:4},{value:"listenerCount",id:"listenercount-1",level:3},{value:"Parameters",id:"parameters-16",level:4},{value:"Returns",id:"returns-19",level:4},{value:"Inherited from",id:"inherited-from-18",level:4},{value:"Defined in",id:"defined-in-23",level:4},{value:"on",id:"on-1",level:3},{value:"Parameters",id:"parameters-17",level:4},{value:"Returns",id:"returns-20",level:4},{value:"Inherited from",id:"inherited-from-19",level:4},{value:"Defined in",id:"defined-in-24",level:4},{value:"Type parameters",id:"type-parameters-3",level:4},{value:"Parameters",id:"parameters-18",level:4},{value:"Returns",id:"returns-21",level:4},{value:"Inherited from",id:"inherited-from-20",level:4},{value:"Defined in",id:"defined-in-25",level:4},{value:"once",id:"once-1",level:3},{value:"Parameters",id:"parameters-19",level:4},{value:"Returns",id:"returns-22",level:4},{value:"Inherited from",id:"inherited-from-21",level:4},{value:"Defined in",id:"defined-in-26",level:4},{value:"Parameters",id:"parameters-20",level:4},{value:"Returns",id:"returns-23",level:4},{value:"Inherited from",id:"inherited-from-22",level:4},{value:"Defined in",id:"defined-in-27",level:4},{value:"Type parameters",id:"type-parameters-4",level:4},{value:"Parameters",id:"parameters-21",level:4},{value:"Returns",id:"returns-24",level:4},{value:"Inherited from",id:"inherited-from-23",level:4},{value:"Defined in",id:"defined-in-28",level:4},{value:"payload",id:"payload",level:3},{value:"Type parameters",id:"type-parameters-5",level:4},{value:"Parameters",id:"parameters-22",level:4},{value:"Returns",id:"returns-25",level:4},{value:"Defined in",id:"defined-in-29",level:4},{value:"setMaxListeners",id:"setmaxlisteners-1",level:3},{value:"Parameters",id:"parameters-23",level:4},{value:"Returns",id:"returns-26",level:4},{value:"Inherited from",id:"inherited-from-24",level:4},{value:"Defined in",id:"defined-in-30",level:4},{value:"success",id:"success",level:3},{value:"Parameters",id:"parameters-24",level:4},{value:"Returns",id:"returns-27",level:4},{value:"Defined in",id:"defined-in-31",level:4},{value:"warning",id:"warning",level:3},{value:"Parameters",id:"parameters-25",level:4},{value:"Returns",id:"returns-28",level:4},{value:"Defined in",id:"defined-in-32",level:4}];function o(e){const n={a:"a",code:"code",em:"em",h2:"h2",h3:"h3",h4:"h4",hr:"hr",li:"li",p:"p",pre:"pre",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,s.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"1.0.0"}),"\n",(0,r.jsx)(n.h2,{id:"hierarchy",children:"Hierarchy"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"EventEmitter"})}),"\n",(0,r.jsxs)(n.p,{children:["\u21b3 ",(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"SernEmitter"})})]}),"\n"]}),"\n"]}),"\n",(0,r.jsx)(n.h2,{id:"constructors",children:"Constructors"}),"\n",(0,r.jsx)(n.h3,{id:"constructor",children:"constructor"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"new SernEmitter"}),"(): ",(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})]}),"\n",(0,r.jsx)(n.h4,{id:"returns",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})}),"\n",(0,r.jsx)(n.h4,{id:"overrides",children:"Overrides"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.constructor"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L10",children:"src/core/structures/sern-emitter.ts:10"})}),"\n",(0,r.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,r.jsx)(n.h3,{id:"capturerejectionsymbol",children:"captureRejectionSymbol"}),"\n",(0,r.jsxs)(n.p,{children:["\u25aa ",(0,r.jsx)(n.code,{children:"Static"})," ",(0,r.jsx)(n.code,{children:"Readonly"})," ",(0,r.jsx)(n.strong,{children:"captureRejectionSymbol"}),": typeof ",(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter#capturerejectionsymbol",children:(0,r.jsx)(n.code,{children:"captureRejectionSymbol"})})]}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.captureRejectionSymbol"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:357"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"capturerejections",children:"captureRejections"}),"\n",(0,r.jsxs)(n.p,{children:["\u25aa ",(0,r.jsx)(n.code,{children:"Static"})," ",(0,r.jsx)(n.strong,{children:"captureRejections"}),": ",(0,r.jsx)(n.code,{children:"boolean"})]}),"\n",(0,r.jsx)(n.p,{children:"Sets or gets the default captureRejection value for all emitters."}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-1",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.captureRejections"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:362"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"defaultmaxlisteners",children:"defaultMaxListeners"}),"\n",(0,r.jsxs)(n.p,{children:["\u25aa ",(0,r.jsx)(n.code,{children:"Static"})," ",(0,r.jsx)(n.strong,{children:"defaultMaxListeners"}),": ",(0,r.jsx)(n.code,{children:"number"})]}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-2",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.defaultMaxListeners"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:363"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"errormonitor",children:"errorMonitor"}),"\n",(0,r.jsxs)(n.p,{children:["\u25aa ",(0,r.jsx)(n.code,{children:"Static"})," ",(0,r.jsx)(n.code,{children:"Readonly"})," ",(0,r.jsx)(n.strong,{children:"errorMonitor"}),": typeof ",(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter#errormonitor",children:(0,r.jsx)(n.code,{children:"errorMonitor"})})]}),"\n",(0,r.jsxs)(n.p,{children:["This symbol shall be used to install a listener for only monitoring ",(0,r.jsx)(n.code,{children:"'error'"}),"\nevents. Listeners installed using this symbol are called before the regular\n",(0,r.jsx)(n.code,{children:"'error'"})," listeners are called."]}),"\n",(0,r.jsxs)(n.p,{children:["Installing a listener using this symbol does not change the behavior once an\n",(0,r.jsx)(n.code,{children:"'error'"})," event is emitted, therefore the process will still crash if no\nregular ",(0,r.jsx)(n.code,{children:"'error'"})," listener is installed."]}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-3",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.errorMonitor"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-4",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:356"}),"\n",(0,r.jsx)(n.h2,{id:"methods",children:"Methods"}),"\n",(0,r.jsx)(n.h3,{id:"addlistener",children:"addListener"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"addListener"}),"(",(0,r.jsx)(n.code,{children:"eventName"}),", ",(0,r.jsx)(n.code,{children:"listener"}),"): ",(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})]}),"\n",(0,r.jsxs)(n.p,{children:["Alias for ",(0,r.jsx)(n.code,{children:"emitter.on(eventName, listener)"}),"."]}),"\n",(0,r.jsx)(n.h4,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"symbol"})]})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"listener"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["(...",(0,r.jsx)(n.code,{children:"args"}),": ",(0,r.jsx)(n.code,{children:"any"}),"[]) => ",(0,r.jsx)(n.code,{children:"void"})]})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-1",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v0.1.26"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-4",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.addListener"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-5",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:383"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"emit",children:"emit"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"emit"}),"<",(0,r.jsx)(n.code,{children:"T"}),">(",(0,r.jsx)(n.code,{children:"eventName"}),", ",(0,r.jsx)(n.code,{children:"...args"}),"): ",(0,r.jsx)(n.code,{children:"boolean"})]}),"\n",(0,r.jsx)(n.p,{children:"Listening to sern events with on. This event stays on until a crash or a normal exit"}),"\n",(0,r.jsx)(n.h4,{id:"type-parameters",children:"Type parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"T"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["extends keyof ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/SernEventsMapping",children:(0,r.jsx)(n.code,{children:"SernEventsMapping"})})]})]})})]}),"\n",(0,r.jsx)(n.h4,{id:"parameters-1",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Description"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"T"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"}})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"...args"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.a,{href:"/docs/api/interfaces/SernEventsMapping",children:(0,r.jsx)(n.code,{children:"SernEventsMapping"})}),"[",(0,r.jsx)(n.code,{children:"T"}),"]"]}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:"the arguments for emitting the eventName"})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-2",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"boolean"})}),"\n",(0,r.jsx)(n.h4,{id:"overrides-1",children:"Overrides"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.emit"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-6",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L40",children:"src/core/structures/sern-emitter.ts:40"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"eventnames",children:"eventNames"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"eventNames"}),"(): (",(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"symbol"}),")[]"]}),"\n",(0,r.jsxs)(n.p,{children:["Returns an array listing the events for which the emitter has registered\nlisteners. The values in the array are strings or ",(0,r.jsx)(n.code,{children:"Symbol"}),"s."]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"const EventEmitter = require('events');\nconst myEE = new EventEmitter();\nmyEE.on('foo', () => {});\nmyEE.on('bar', () => {});\n\nconst sym = Symbol('symbol');\nmyEE.on(sym, () => {});\n\nconsole.log(myEE.eventNames());\n// Prints: [ 'foo', 'bar', Symbol(symbol) ]\n"})}),"\n",(0,r.jsx)(n.h4,{id:"returns-3",children:"Returns"}),"\n",(0,r.jsxs)(n.p,{children:["(",(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"symbol"}),")[]"]}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v6.0.0"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-5",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.eventNames"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-7",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:702"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"getmaxlisteners",children:"getMaxListeners"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"getMaxListeners"}),"(): ",(0,r.jsx)(n.code,{children:"number"})]}),"\n",(0,r.jsxs)(n.p,{children:["Returns the current max listener value for the ",(0,r.jsx)(n.code,{children:"EventEmitter"})," which is either\nset by ",(0,r.jsx)(n.code,{children:"emitter.setMaxListeners(n)"})," or defaults to ",(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter#defaultmaxlisteners",children:"defaultMaxListeners"}),"."]}),"\n",(0,r.jsx)(n.h4,{id:"returns-4",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"number"})}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v1.0.0"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-6",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.getMaxListeners"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-8",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:555"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"listenercount",children:"listenerCount"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"listenerCount"}),"(",(0,r.jsx)(n.code,{children:"eventName"}),", ",(0,r.jsx)(n.code,{children:"listener?"}),"): ",(0,r.jsx)(n.code,{children:"number"})]}),"\n",(0,r.jsxs)(n.p,{children:["Returns the number of listeners listening to the event named ",(0,r.jsx)(n.code,{children:"eventName"}),"."]}),"\n",(0,r.jsxs)(n.p,{children:["If ",(0,r.jsx)(n.code,{children:"listener"})," is provided, it will return how many times the listener\nis found in the list of the listeners of the event."]}),"\n",(0,r.jsx)(n.h4,{id:"parameters-2",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Description"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"symbol"})]}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:"The name of the event being listened for"})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"listener?"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"Function"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:"The event handler function"})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-5",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"number"})}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v3.2.0"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-7",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.listenerCount"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-9",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:649"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"listeners",children:"listeners"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"listeners"}),"(",(0,r.jsx)(n.code,{children:"eventName"}),"): ",(0,r.jsx)(n.code,{children:"Function"}),"[]"]}),"\n",(0,r.jsxs)(n.p,{children:["Returns a copy of the array of listeners for the event named ",(0,r.jsx)(n.code,{children:"eventName"}),"."]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"server.on('connection', (stream) => {\n console.log('someone connected!');\n});\nconsole.log(util.inspect(server.listeners('connection')));\n// Prints: [ [Function] ]\n"})}),"\n",(0,r.jsx)(n.h4,{id:"parameters-3",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"symbol"})]})]})})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-6",children:"Returns"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.code,{children:"Function"}),"[]"]}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v0.1.26"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-8",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.listeners"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-10",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:568"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"off",children:"off"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"off"}),"(",(0,r.jsx)(n.code,{children:"eventName"}),", ",(0,r.jsx)(n.code,{children:"listener"}),"): ",(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})]}),"\n",(0,r.jsxs)(n.p,{children:["Alias for ",(0,r.jsx)(n.code,{children:"emitter.removeListener()"}),"."]}),"\n",(0,r.jsx)(n.h4,{id:"parameters-4",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"symbol"})]})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"listener"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["(...",(0,r.jsx)(n.code,{children:"args"}),": ",(0,r.jsx)(n.code,{children:"any"}),"[]) => ",(0,r.jsx)(n.code,{children:"void"})]})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-7",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v10.0.0"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-9",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.off"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-11",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:528"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"on",children:"on"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"on"}),"<",(0,r.jsx)(n.code,{children:"T"}),">(",(0,r.jsx)(n.code,{children:"eventName"}),", ",(0,r.jsx)(n.code,{children:"listener"}),"): ",(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})]}),"\n",(0,r.jsx)(n.p,{children:"Listening to sern events with on. This event stays on until a crash or a normal exit"}),"\n",(0,r.jsx)(n.h4,{id:"type-parameters-1",children:"Type parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"T"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["extends keyof ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/SernEventsMapping",children:(0,r.jsx)(n.code,{children:"SernEventsMapping"})})]})]})})]}),"\n",(0,r.jsx)(n.h4,{id:"parameters-5",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Description"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"T"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"}})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"listener"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["(...",(0,r.jsx)(n.code,{children:"args"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/SernEventsMapping",children:(0,r.jsx)(n.code,{children:"SernEventsMapping"})}),"[",(0,r.jsx)(n.code,{children:"T"}),"][]) => ",(0,r.jsx)(n.code,{children:"void"})]}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:"what to do with the data"})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-8",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})}),"\n",(0,r.jsx)(n.h4,{id:"overrides-2",children:"Overrides"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.on"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-12",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L18",children:"src/core/structures/sern-emitter.ts:18"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"once",children:"once"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"once"}),"<",(0,r.jsx)(n.code,{children:"T"}),">(",(0,r.jsx)(n.code,{children:"eventName"}),", ",(0,r.jsx)(n.code,{children:"listener"}),"): ",(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})]}),"\n",(0,r.jsx)(n.p,{children:"Listening to sern events with on. This event stays on until a crash or a normal exit"}),"\n",(0,r.jsx)(n.h4,{id:"type-parameters-2",children:"Type parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"T"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["extends keyof ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/SernEventsMapping",children:(0,r.jsx)(n.code,{children:"SernEventsMapping"})})]})]})})]}),"\n",(0,r.jsx)(n.h4,{id:"parameters-6",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Description"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"T"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"}})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"listener"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["(...",(0,r.jsx)(n.code,{children:"args"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/SernEventsMapping",children:(0,r.jsx)(n.code,{children:"SernEventsMapping"})}),"[",(0,r.jsx)(n.code,{children:"T"}),"][]) => ",(0,r.jsx)(n.code,{children:"void"})]}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:"what to do with the data"})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-9",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})}),"\n",(0,r.jsx)(n.h4,{id:"overrides-3",children:"Overrides"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.once"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-13",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L29",children:"src/core/structures/sern-emitter.ts:29"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"prependlistener",children:"prependListener"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"prependListener"}),"(",(0,r.jsx)(n.code,{children:"eventName"}),", ",(0,r.jsx)(n.code,{children:"listener"}),"): ",(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})]}),"\n",(0,r.jsxs)(n.p,{children:["Adds the ",(0,r.jsx)(n.code,{children:"listener"})," function to the ",(0,r.jsx)(n.em,{children:"beginning"})," of the listeners array for the\nevent named ",(0,r.jsx)(n.code,{children:"eventName"}),". No checks are made to see if the ",(0,r.jsx)(n.code,{children:"listener"})," has\nalready been added. Multiple calls passing the same combination of ",(0,r.jsx)(n.code,{children:"eventName"}),"and ",(0,r.jsx)(n.code,{children:"listener"})," will result in the ",(0,r.jsx)(n.code,{children:"listener"})," being added, and called, multiple\ntimes."]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"server.prependListener('connection', (stream) => {\n console.log('someone connected!');\n});\n"})}),"\n",(0,r.jsxs)(n.p,{children:["Returns a reference to the ",(0,r.jsx)(n.code,{children:"EventEmitter"}),", so that calls can be chained."]}),"\n",(0,r.jsx)(n.h4,{id:"parameters-7",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Description"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"symbol"})]}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:"The name of the event."})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"listener"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["(...",(0,r.jsx)(n.code,{children:"args"}),": ",(0,r.jsx)(n.code,{children:"any"}),"[]) => ",(0,r.jsx)(n.code,{children:"void"})]}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:"The callback function"})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-10",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v6.0.0"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-10",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.prependListener"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-14",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:667"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"prependoncelistener",children:"prependOnceListener"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"prependOnceListener"}),"(",(0,r.jsx)(n.code,{children:"eventName"}),", ",(0,r.jsx)(n.code,{children:"listener"}),"): ",(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})]}),"\n",(0,r.jsxs)(n.p,{children:["Adds a ",(0,r.jsx)(n.strong,{children:"one-time"}),(0,r.jsx)(n.code,{children:"listener"})," function for the event named ",(0,r.jsx)(n.code,{children:"eventName"})," to the ",(0,r.jsx)(n.em,{children:"beginning"})," of the listeners array. The next time ",(0,r.jsx)(n.code,{children:"eventName"})," is triggered, this\nlistener is removed, and then invoked."]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"server.prependOnceListener('connection', (stream) => {\n console.log('Ah, we have our first user!');\n});\n"})}),"\n",(0,r.jsxs)(n.p,{children:["Returns a reference to the ",(0,r.jsx)(n.code,{children:"EventEmitter"}),", so that calls can be chained."]}),"\n",(0,r.jsx)(n.h4,{id:"parameters-8",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Description"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"symbol"})]}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:"The name of the event."})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"listener"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["(...",(0,r.jsx)(n.code,{children:"args"}),": ",(0,r.jsx)(n.code,{children:"any"}),"[]) => ",(0,r.jsx)(n.code,{children:"void"})]}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:"The callback function"})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-11",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v6.0.0"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-11",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.prependOnceListener"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-15",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:683"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"rawlisteners",children:"rawListeners"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"rawListeners"}),"(",(0,r.jsx)(n.code,{children:"eventName"}),"): ",(0,r.jsx)(n.code,{children:"Function"}),"[]"]}),"\n",(0,r.jsxs)(n.p,{children:["Returns a copy of the array of listeners for the event named ",(0,r.jsx)(n.code,{children:"eventName"}),",\nincluding any wrappers (such as those created by ",(0,r.jsx)(n.code,{children:".once()"}),")."]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"const emitter = new EventEmitter();\nemitter.once('log', () => console.log('log once'));\n\n// Returns a new Array with a function `onceWrapper` which has a property\n// `listener` which contains the original listener bound above\nconst listeners = emitter.rawListeners('log');\nconst logFnWrapper = listeners[0];\n\n// Logs \"log once\" to the console and does not unbind the `once` event\nlogFnWrapper.listener();\n\n// Logs \"log once\" to the console and removes the listener\nlogFnWrapper();\n\nemitter.on('log', () => console.log('log persistently'));\n// Will return a new Array with a single function bound by `.on()` above\nconst newListeners = emitter.rawListeners('log');\n\n// Logs \"log persistently\" twice\nnewListeners[0]();\nemitter.emit('log');\n"})}),"\n",(0,r.jsx)(n.h4,{id:"parameters-9",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"symbol"})]})]})})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-12",children:"Returns"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.code,{children:"Function"}),"[]"]}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v9.4.0"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-12",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.rawListeners"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-16",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:598"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"removealllisteners",children:"removeAllListeners"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"removeAllListeners"}),"(",(0,r.jsx)(n.code,{children:"event?"}),"): ",(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})]}),"\n",(0,r.jsxs)(n.p,{children:["Removes all listeners, or those of the specified ",(0,r.jsx)(n.code,{children:"eventName"}),"."]}),"\n",(0,r.jsxs)(n.p,{children:["It is bad practice to remove listeners added elsewhere in the code,\nparticularly when the ",(0,r.jsx)(n.code,{children:"EventEmitter"})," instance was created by some other\ncomponent or module (e.g. sockets or file streams)."]}),"\n",(0,r.jsxs)(n.p,{children:["Returns a reference to the ",(0,r.jsx)(n.code,{children:"EventEmitter"}),", so that calls can be chained."]}),"\n",(0,r.jsx)(n.h4,{id:"parameters-10",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"event?"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"symbol"})]})]})})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-13",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v0.1.26"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-13",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.removeAllListeners"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-17",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:539"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"removelistener",children:"removeListener"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"removeListener"}),"(",(0,r.jsx)(n.code,{children:"eventName"}),", ",(0,r.jsx)(n.code,{children:"listener"}),"): ",(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})]}),"\n",(0,r.jsxs)(n.p,{children:["Removes the specified ",(0,r.jsx)(n.code,{children:"listener"})," from the listener array for the event named",(0,r.jsx)(n.code,{children:"eventName"}),"."]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"const callback = (stream) => {\n console.log('someone connected!');\n};\nserver.on('connection', callback);\n// ...\nserver.removeListener('connection', callback);\n"})}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.code,{children:"removeListener()"})," will remove, at most, one instance of a listener from the\nlistener array. If any single listener has been added multiple times to the\nlistener array for the specified ",(0,r.jsx)(n.code,{children:"eventName"}),", then ",(0,r.jsx)(n.code,{children:"removeListener()"})," must be\ncalled multiple times to remove each instance."]}),"\n",(0,r.jsxs)(n.p,{children:["Once an event is emitted, all listeners attached to it at the\ntime of emitting are called in order. This implies that any",(0,r.jsx)(n.code,{children:"removeListener()"})," or ",(0,r.jsx)(n.code,{children:"removeAllListeners()"})," calls ",(0,r.jsx)(n.em,{children:"after"})," emitting and ",(0,r.jsx)(n.em,{children:"before"})," the last listener finishes execution\nwill not remove them from",(0,r.jsx)(n.code,{children:"emit()"})," in progress. Subsequent events behave as expected."]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"const myEmitter = new MyEmitter();\n\nconst callbackA = () => {\n console.log('A');\n myEmitter.removeListener('event', callbackB);\n};\n\nconst callbackB = () => {\n console.log('B');\n};\n\nmyEmitter.on('event', callbackA);\n\nmyEmitter.on('event', callbackB);\n\n// callbackA removes listener callbackB but it will still be called.\n// Internal listener array at time of emit [callbackA, callbackB]\nmyEmitter.emit('event');\n// Prints:\n// A\n// B\n\n// callbackB is now removed.\n// Internal listener array [callbackA]\nmyEmitter.emit('event');\n// Prints:\n// A\n"})}),"\n",(0,r.jsxs)(n.p,{children:["Because listeners are managed using an internal array, calling this will\nchange the position indices of any listener registered ",(0,r.jsx)(n.em,{children:"after"})," the listener\nbeing removed. This will not impact the order in which listeners are called,\nbut it means that any copies of the listener array as returned by\nthe ",(0,r.jsx)(n.code,{children:"emitter.listeners()"})," method will need to be recreated."]}),"\n",(0,r.jsxs)(n.p,{children:["When a single function has been added as a handler multiple times for a single\nevent (as in the example below), ",(0,r.jsx)(n.code,{children:"removeListener()"})," will remove the most\nrecently added instance. In the example the ",(0,r.jsx)(n.code,{children:"once('ping')"}),"listener is removed:"]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"const ee = new EventEmitter();\n\nfunction pong() {\n console.log('pong');\n}\n\nee.on('ping', pong);\nee.once('ping', pong);\nee.removeListener('ping', pong);\n\nee.emit('ping');\nee.emit('ping');\n"})}),"\n",(0,r.jsxs)(n.p,{children:["Returns a reference to the ",(0,r.jsx)(n.code,{children:"EventEmitter"}),", so that calls can be chained."]}),"\n",(0,r.jsx)(n.h4,{id:"parameters-11",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"symbol"})]})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"listener"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["(...",(0,r.jsx)(n.code,{children:"args"}),": ",(0,r.jsx)(n.code,{children:"any"}),"[]) => ",(0,r.jsx)(n.code,{children:"void"})]})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-14",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v0.1.26"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-14",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.removeListener"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-18",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:523"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"setmaxlisteners",children:"setMaxListeners"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"setMaxListeners"}),"(",(0,r.jsx)(n.code,{children:"n"}),"): ",(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})]}),"\n",(0,r.jsxs)(n.p,{children:["By default ",(0,r.jsx)(n.code,{children:"EventEmitter"}),"s will print a warning if more than ",(0,r.jsx)(n.code,{children:"10"})," listeners are\nadded for a particular event. This is a useful default that helps finding\nmemory leaks. The ",(0,r.jsx)(n.code,{children:"emitter.setMaxListeners()"})," method allows the limit to be\nmodified for this specific ",(0,r.jsx)(n.code,{children:"EventEmitter"})," instance. The value can be set to",(0,r.jsx)(n.code,{children:"Infinity"})," (or ",(0,r.jsx)(n.code,{children:"0"}),") to indicate an unlimited number of listeners."]}),"\n",(0,r.jsxs)(n.p,{children:["Returns a reference to the ",(0,r.jsx)(n.code,{children:"EventEmitter"}),", so that calls can be chained."]}),"\n",(0,r.jsx)(n.h4,{id:"parameters-12",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"n"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"number"})})]})})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-15",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"/docs/api/classes/SernEmitter",children:(0,r.jsx)(n.code,{children:"SernEmitter"})})}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v0.3.5"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-15",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.setMaxListeners"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-19",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:549"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"failure",children:"failure"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"failure"}),"(",(0,r.jsx)(n.code,{children:"module?"}),", ",(0,r.jsx)(n.code,{children:"reason?"}),"): ",(0,r.jsx)(n.code,{children:"Object"})]}),"\n",(0,r.jsx)(n.p,{children:"Creates a compliant SernEmitter failure payload"}),"\n",(0,r.jsx)(n.h4,{id:"parameters-13",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"module?"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"Module"})})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"reason?"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"unknown"})})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-16",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"Object"})}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"module?"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"AnyModule"})})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"reason"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"Error"})]})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"type"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.a,{href:"/docs/api/enums/PayloadType#failure",children:(0,r.jsx)(n.code,{children:"Failure"})})})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-20",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L59",children:"src/core/structures/sern-emitter.ts:59"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"geteventlisteners",children:"getEventListeners"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"getEventListeners"}),"(",(0,r.jsx)(n.code,{children:"emitter"}),", ",(0,r.jsx)(n.code,{children:"name"}),"): ",(0,r.jsx)(n.code,{children:"Function"}),"[]"]}),"\n",(0,r.jsxs)(n.p,{children:["Returns a copy of the array of listeners for the event named ",(0,r.jsx)(n.code,{children:"eventName"}),"."]}),"\n",(0,r.jsxs)(n.p,{children:["For ",(0,r.jsx)(n.code,{children:"EventEmitter"}),"s this behaves exactly the same as calling ",(0,r.jsx)(n.code,{children:".listeners"})," on\nthe emitter."]}),"\n",(0,r.jsxs)(n.p,{children:["For ",(0,r.jsx)(n.code,{children:"EventTarget"}),"s this is the only way to get the event listeners for the\nevent target. This is useful for debugging and diagnostic purposes."]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"const { getEventListeners, EventEmitter } = require('events');\n\n{\n const ee = new EventEmitter();\n const listener = () => console.log('Events are fun');\n ee.on('foo', listener);\n getEventListeners(ee, 'foo'); // [listener]\n}\n{\n const et = new EventTarget();\n const listener = () => console.log('Events are fun');\n et.addEventListener('foo', listener);\n getEventListeners(et, 'foo'); // [listener]\n}\n"})}),"\n",(0,r.jsx)(n.h4,{id:"parameters-14",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"emitter"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"EventEmitter"})," | ",(0,r.jsx)(n.code,{children:"_DOMEventTarget"})]})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"name"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"symbol"})]})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-17",children:"Returns"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.code,{children:"Function"}),"[]"]}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v15.2.0, v14.17.0"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-16",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.getEventListeners"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-21",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:299"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"getmaxlisteners-1",children:"getMaxListeners"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"getMaxListeners"}),"(",(0,r.jsx)(n.code,{children:"emitter"}),"): ",(0,r.jsx)(n.code,{children:"number"})]}),"\n",(0,r.jsx)(n.p,{children:"Returns the currently set max amount of listeners."}),"\n",(0,r.jsxs)(n.p,{children:["For ",(0,r.jsx)(n.code,{children:"EventEmitter"}),"s this behaves exactly the same as calling ",(0,r.jsx)(n.code,{children:".getMaxListeners"})," on\nthe emitter."]}),"\n",(0,r.jsxs)(n.p,{children:["For ",(0,r.jsx)(n.code,{children:"EventTarget"}),"s this is the only way to get the max event listeners for the\nevent target. If the number of event handlers on a single EventTarget exceeds\nthe max set, the EventTarget will print a warning."]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"import { getMaxListeners, setMaxListeners, EventEmitter } from 'node:events';\n\n{\n const ee = new EventEmitter();\n console.log(getMaxListeners(ee)); // 10\n setMaxListeners(11, ee);\n console.log(getMaxListeners(ee)); // 11\n}\n{\n const et = new EventTarget();\n console.log(getMaxListeners(et)); // 10\n setMaxListeners(11, et);\n console.log(getMaxListeners(et)); // 11\n}\n"})}),"\n",(0,r.jsx)(n.h4,{id:"parameters-15",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"emitter"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"EventEmitter"})," | ",(0,r.jsx)(n.code,{children:"_DOMEventTarget"})]})]})})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-18",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"number"})}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v18.17.0"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-17",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.getMaxListeners"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-22",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:328"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"listenercount-1",children:"listenerCount"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"listenerCount"}),"(",(0,r.jsx)(n.code,{children:"emitter"}),", ",(0,r.jsx)(n.code,{children:"eventName"}),"): ",(0,r.jsx)(n.code,{children:"number"})]}),"\n",(0,r.jsxs)(n.p,{children:["A class method that returns the number of listeners for the given ",(0,r.jsx)(n.code,{children:"eventName"}),"registered on the given ",(0,r.jsx)(n.code,{children:"emitter"}),"."]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"const { EventEmitter, listenerCount } = require('events');\nconst myEmitter = new EventEmitter();\nmyEmitter.on('event', () => {});\nmyEmitter.on('event', () => {});\nconsole.log(listenerCount(myEmitter, 'event'));\n// Prints: 2\n"})}),"\n",(0,r.jsx)(n.h4,{id:"parameters-16",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Description"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"emitter"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"EventEmitter"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:"The emitter to query"})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"symbol"})]}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:"The event name"})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-19",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"number"})}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v0.9.12"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Deprecated"})})}),"\n",(0,r.jsxs)(n.p,{children:["Since v3.2.0 - Use ",(0,r.jsx)(n.code,{children:"listenerCount"})," instead."]}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-18",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.listenerCount"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-23",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:271"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"on-1",children:"on"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"on"}),"(",(0,r.jsx)(n.code,{children:"emitter"}),", ",(0,r.jsx)(n.code,{children:"eventName"}),", ",(0,r.jsx)(n.code,{children:"options?"}),"): ",(0,r.jsx)(n.code,{children:"AsyncIterableIterator"}),"<",(0,r.jsx)(n.code,{children:"any"}),">"]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"const { on, EventEmitter } = require('events');\n\n(async () => {\n const ee = new EventEmitter();\n\n // Emit later on\n process.nextTick(() => {\n ee.emit('foo', 'bar');\n ee.emit('foo', 42);\n });\n\n for await (const event of on(ee, 'foo')) {\n // The execution of this inner block is synchronous and it\n // processes one event at a time (even with await). Do not use\n // if concurrent execution is required.\n console.log(event); // prints ['bar'] [42]\n }\n // Unreachable here\n})();\n"})}),"\n",(0,r.jsxs)(n.p,{children:["Returns an ",(0,r.jsx)(n.code,{children:"AsyncIterator"})," that iterates ",(0,r.jsx)(n.code,{children:"eventName"})," events. It will throw\nif the ",(0,r.jsx)(n.code,{children:"EventEmitter"})," emits ",(0,r.jsx)(n.code,{children:"'error'"}),". It removes all listeners when\nexiting the loop. The ",(0,r.jsx)(n.code,{children:"value"})," returned by each iteration is an array\ncomposed of the emitted event arguments."]}),"\n",(0,r.jsxs)(n.p,{children:["An ",(0,r.jsx)(n.code,{children:"AbortSignal"})," can be used to cancel waiting on events:"]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"const { on, EventEmitter } = require('events');\nconst ac = new AbortController();\n\n(async () => {\n const ee = new EventEmitter();\n\n // Emit later on\n process.nextTick(() => {\n ee.emit('foo', 'bar');\n ee.emit('foo', 42);\n });\n\n for await (const event of on(ee, 'foo', { signal: ac.signal })) {\n // The execution of this inner block is synchronous and it\n // processes one event at a time (even with await). Do not use\n // if concurrent execution is required.\n console.log(event); // prints ['bar'] [42]\n }\n // Unreachable here\n})();\n\nprocess.nextTick(() => ac.abort());\n"})}),"\n",(0,r.jsx)(n.h4,{id:"parameters-17",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Description"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"emitter"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"EventEmitter"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:"-"})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"string"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:"The name of the event being listened for"})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"options?"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"StaticEventEmitterOptions"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:"-"})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-20",children:"Returns"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.code,{children:"AsyncIterableIterator"}),"<",(0,r.jsx)(n.code,{children:"any"}),">"]}),"\n",(0,r.jsxs)(n.p,{children:["that iterates ",(0,r.jsx)(n.code,{children:"eventName"})," events emitted by the ",(0,r.jsx)(n.code,{children:"emitter"})]}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v13.6.0, v12.16.0"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-19",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.on"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-24",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:254"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"on"}),"<",(0,r.jsx)(n.code,{children:"Emitter"}),", ",(0,r.jsx)(n.code,{children:"Events"}),">(",(0,r.jsx)(n.code,{children:"eventEmitter"}),", ",(0,r.jsx)(n.code,{children:"eventName"}),"): ",(0,r.jsx)(n.code,{children:"AsyncIterableIterator"}),"<",(0,r.jsx)(n.code,{children:"Emitter"})," extends ",(0,r.jsx)(n.code,{children:"Client"}),"<",(0,r.jsx)(n.code,{children:"boolean"}),"> ? ",(0,r.jsx)(n.code,{children:"ClientEvents"}),"[",(0,r.jsx)(n.code,{children:"Events"}),"] : ",(0,r.jsx)(n.code,{children:"any"}),">"]}),"\n",(0,r.jsx)(n.h4,{id:"type-parameters-3",children:"Type parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"Emitter"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["extends ",(0,r.jsx)(n.code,{children:"__module"})]})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"Events"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["extends keyof ",(0,r.jsx)(n.code,{children:"ClientEvents"})]})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"parameters-18",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventEmitter"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"Emitter"})})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"Emitter"})," extends ",(0,r.jsx)(n.code,{children:"Client"}),"<",(0,r.jsx)(n.code,{children:"boolean"}),"> ? ",(0,r.jsx)(n.code,{children:"Events"})," : ",(0,r.jsx)(n.code,{children:"string"})]})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-21",children:"Returns"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.code,{children:"AsyncIterableIterator"}),"<",(0,r.jsx)(n.code,{children:"Emitter"})," extends ",(0,r.jsx)(n.code,{children:"Client"}),"<",(0,r.jsx)(n.code,{children:"boolean"}),"> ? ",(0,r.jsx)(n.code,{children:"ClientEvents"}),"[",(0,r.jsx)(n.code,{children:"Events"}),"] : ",(0,r.jsx)(n.code,{children:"any"}),">"]}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-20",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.on"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-25",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/discord.js/typings/index.d.ts:243"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"once-1",children:"once"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"once"}),"(",(0,r.jsx)(n.code,{children:"emitter"}),", ",(0,r.jsx)(n.code,{children:"eventName"}),", ",(0,r.jsx)(n.code,{children:"options?"}),"): ",(0,r.jsx)(n.code,{children:"Promise"}),"<",(0,r.jsx)(n.code,{children:"any"}),"[]>"]}),"\n",(0,r.jsxs)(n.p,{children:["Creates a ",(0,r.jsx)(n.code,{children:"Promise"})," that is fulfilled when the ",(0,r.jsx)(n.code,{children:"EventEmitter"})," emits the given\nevent or that is rejected if the ",(0,r.jsx)(n.code,{children:"EventEmitter"})," emits ",(0,r.jsx)(n.code,{children:"'error'"})," while waiting.\nThe ",(0,r.jsx)(n.code,{children:"Promise"})," will resolve with an array of all the arguments emitted to the\ngiven event."]}),"\n",(0,r.jsxs)(n.p,{children:["This method is intentionally generic and works with the web platform ",(0,r.jsx)(n.a,{href:"https://dom.spec.whatwg.org/#interface-eventtarget",children:"EventTarget"})," interface, which has no special",(0,r.jsx)(n.code,{children:"'error'"})," event\nsemantics and does not listen to the ",(0,r.jsx)(n.code,{children:"'error'"})," event."]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"const { once, EventEmitter } = require('events');\n\nasync function run() {\n const ee = new EventEmitter();\n\n process.nextTick(() => {\n ee.emit('myevent', 42);\n });\n\n const [value] = await once(ee, 'myevent');\n console.log(value);\n\n const err = new Error('kaboom');\n process.nextTick(() => {\n ee.emit('error', err);\n });\n\n try {\n await once(ee, 'myevent');\n } catch (err) {\n console.log('error happened', err);\n }\n}\n\nrun();\n"})}),"\n",(0,r.jsxs)(n.p,{children:["The special handling of the ",(0,r.jsx)(n.code,{children:"'error'"})," event is only used when ",(0,r.jsx)(n.code,{children:"events.once()"}),"is used to wait for another event. If ",(0,r.jsx)(n.code,{children:"events.once()"})," is used to wait for the\n'",(0,r.jsx)(n.code,{children:"error'"})," event itself, then it is treated as any other kind of event without\nspecial handling:"]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"const { EventEmitter, once } = require('events');\n\nconst ee = new EventEmitter();\n\nonce(ee, 'error')\n .then(([err]) => console.log('ok', err.message))\n .catch((err) => console.log('error', err.message));\n\nee.emit('error', new Error('boom'));\n\n// Prints: ok boom\n"})}),"\n",(0,r.jsxs)(n.p,{children:["An ",(0,r.jsx)(n.code,{children:"AbortSignal"})," can be used to cancel waiting for the event:"]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"const { EventEmitter, once } = require('events');\n\nconst ee = new EventEmitter();\nconst ac = new AbortController();\n\nasync function foo(emitter, event, signal) {\n try {\n await once(emitter, event, { signal });\n console.log('event emitted!');\n } catch (error) {\n if (error.name === 'AbortError') {\n console.error('Waiting for the event was canceled!');\n } else {\n console.error('There was an error', error.message);\n }\n }\n}\n\nfoo(ee, 'foo', ac.signal);\nac.abort(); // Abort waiting for the event\nee.emit('foo'); // Prints: Waiting for the event was canceled!\n"})}),"\n",(0,r.jsx)(n.h4,{id:"parameters-19",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"emitter"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"_NodeEventTarget"})})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"symbol"})]})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"options?"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"StaticEventEmitterOptions"})})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-22",children:"Returns"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.code,{children:"Promise"}),"<",(0,r.jsx)(n.code,{children:"any"}),"[]>"]}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v11.13.0, v10.16.0"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-21",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.once"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-26",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:194"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"once"}),"(",(0,r.jsx)(n.code,{children:"emitter"}),", ",(0,r.jsx)(n.code,{children:"eventName"}),", ",(0,r.jsx)(n.code,{children:"options?"}),"): ",(0,r.jsx)(n.code,{children:"Promise"}),"<",(0,r.jsx)(n.code,{children:"any"}),"[]>"]}),"\n",(0,r.jsx)(n.h4,{id:"parameters-20",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"emitter"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"_DOMEventTarget"})})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"string"})})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"options?"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"StaticEventEmitterOptions"})})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-23",children:"Returns"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.code,{children:"Promise"}),"<",(0,r.jsx)(n.code,{children:"any"}),"[]>"]}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-22",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.once"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-27",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:195"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"once"}),"<",(0,r.jsx)(n.code,{children:"Emitter"}),", ",(0,r.jsx)(n.code,{children:"Event"}),">(",(0,r.jsx)(n.code,{children:"eventEmitter"}),", ",(0,r.jsx)(n.code,{children:"eventName"}),"): ",(0,r.jsx)(n.code,{children:"Promise"}),"<",(0,r.jsx)(n.code,{children:"Emitter"})," extends ",(0,r.jsx)(n.code,{children:"Client"}),"<",(0,r.jsx)(n.code,{children:"boolean"}),"> ? ",(0,r.jsx)(n.code,{children:"ClientEvents"}),"[",(0,r.jsx)(n.code,{children:"Event"}),"] : ",(0,r.jsx)(n.code,{children:"any"}),"[]>"]}),"\n",(0,r.jsx)(n.h4,{id:"type-parameters-4",children:"Type parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"Emitter"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["extends ",(0,r.jsx)(n.code,{children:"__module"})]})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"Event"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["extends keyof ",(0,r.jsx)(n.code,{children:"ClientEvents"})]})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"parameters-21",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventEmitter"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"Emitter"})})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"eventName"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"Emitter"})," extends ",(0,r.jsx)(n.code,{children:"Client"}),"<",(0,r.jsx)(n.code,{children:"boolean"}),"> ? ",(0,r.jsx)(n.code,{children:"Event"})," : ",(0,r.jsx)(n.code,{children:"string"})]})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-24",children:"Returns"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.code,{children:"Promise"}),"<",(0,r.jsx)(n.code,{children:"Emitter"})," extends ",(0,r.jsx)(n.code,{children:"Client"}),"<",(0,r.jsx)(n.code,{children:"boolean"}),"> ? ",(0,r.jsx)(n.code,{children:"ClientEvents"}),"[",(0,r.jsx)(n.code,{children:"Event"}),"] : ",(0,r.jsx)(n.code,{children:"any"}),"[]>"]}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-23",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.once"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-28",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/discord.js/typings/index.d.ts:239"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"payload",children:"payload"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"payload"}),"<",(0,r.jsx)(n.code,{children:"T"}),">(",(0,r.jsx)(n.code,{children:"type"}),", ",(0,r.jsx)(n.code,{children:"module?"}),", ",(0,r.jsx)(n.code,{children:"reason?"}),"): ",(0,r.jsx)(n.code,{children:"T"})]}),"\n",(0,r.jsx)(n.h4,{id:"type-parameters-5",children:"Type parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"T"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["extends ",(0,r.jsx)(n.a,{href:"/docs/api/modules#payload",children:(0,r.jsx)(n.code,{children:"Payload"})})]})]})})]}),"\n",(0,r.jsx)(n.h4,{id:"parameters-22",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"type"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.a,{href:"/docs/api/enums/PayloadType",children:(0,r.jsx)(n.code,{children:"PayloadType"})})})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"module?"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"Module"})})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"reason?"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"unknown"})})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-25",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"T"})}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-29",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L46",children:"src/core/structures/sern-emitter.ts:46"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"setmaxlisteners-1",children:"setMaxListeners"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"setMaxListeners"}),"(",(0,r.jsx)(n.code,{children:"n?"}),", ",(0,r.jsx)(n.code,{children:"...eventTargets"}),"): ",(0,r.jsx)(n.code,{children:"void"})]}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-js",children:"const {\n setMaxListeners,\n EventEmitter\n} = require('events');\n\nconst target = new EventTarget();\nconst emitter = new EventEmitter();\n\nsetMaxListeners(5, target, emitter);\n"})}),"\n",(0,r.jsx)(n.h4,{id:"parameters-23",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Description"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"n?"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"number"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["A non-negative number. The maximum number of listeners per ",(0,r.jsx)(n.code,{children:"EventTarget"})," event."]})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"...eventTargets"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["(",(0,r.jsx)(n.code,{children:"EventEmitter"})," | ",(0,r.jsx)(n.code,{children:"_DOMEventTarget"}),")[]"]}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:"-"})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-26",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"void"})}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"v15.4.0"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-24",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"EventEmitter.setMaxListeners"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-30",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:"node_modules/@types/node/events.d.ts:346"}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"success",children:"success"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"success"}),"(",(0,r.jsx)(n.code,{children:"module"}),"): ",(0,r.jsx)(n.code,{children:"Object"})]}),"\n",(0,r.jsx)(n.p,{children:"Creates a compliant SernEmitter module success payload"}),"\n",(0,r.jsx)(n.h4,{id:"parameters-24",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"module"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"Module"})})]})})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-27",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"Object"})}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"module"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"AnyModule"})})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"type"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.a,{href:"/docs/api/enums/PayloadType#success",children:(0,r.jsx)(n.code,{children:"Success"})})})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-31",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L72",children:"src/core/structures/sern-emitter.ts:72"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"warning",children:"warning"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 ",(0,r.jsx)(n.strong,{children:"warning"}),"(",(0,r.jsx)(n.code,{children:"reason"}),"): ",(0,r.jsx)(n.code,{children:"Object"})]}),"\n",(0,r.jsx)(n.p,{children:"Creates a compliant SernEmitter module warning payload"}),"\n",(0,r.jsx)(n.h4,{id:"parameters-25",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"reason"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"unknown"})})]})})]}),"\n",(0,r.jsx)(n.h4,{id:"returns-28",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"Object"})}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"reason"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"string"})})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"type"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.a,{href:"/docs/api/enums/PayloadType#warning",children:(0,r.jsx)(n.code,{children:"Warning"})})})]})]})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-32",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/structures/sern-emitter.ts#L82",children:"src/core/structures/sern-emitter.ts:82"})})]})}function x(e={}){const{wrapper:n}={...(0,s.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(o,{...e})}):o(e)}},8453:(e,n,t)=>{t.d(n,{R:()=>l,x:()=>d});var r=t(6540);const s={},i=r.createContext(s);function l(e){const n=r.useContext(i);return r.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function d(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:l(e.components),r.createElement(i.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/7f2ac8b7.126f370e.js b/assets/js/7f2ac8b7.126f370e.js deleted file mode 100644 index 819acb8cb..000000000 --- a/assets/js/7f2ac8b7.126f370e.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[9368],{5051:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>c,contentTitle:()=>l,default:()=>h,frontMatter:()=>d,metadata:()=>s,toc:()=>o});var r=t(4848),i=t(8453);const d={id:"AutocompleteCommand",title:"Interface: AutocompleteCommand",sidebar_label:"AutocompleteCommand",sidebar_position:0,custom_edit_url:null},l=void 0,s={id:"api/interfaces/AutocompleteCommand",title:"Interface: AutocompleteCommand",description:"Hierarchy",source:"@site/docs/api/interfaces/AutocompleteCommand.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/AutocompleteCommand",permalink:"/docs/api/interfaces/AutocompleteCommand",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"AutocompleteCommand",title:"Interface: AutocompleteCommand",sidebar_label:"AutocompleteCommand",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"SernEmitter",permalink:"/docs/api/classes/SernEmitter"},next:{title:"AutocompletePlugin",permalink:"/docs/api/interfaces/AutocompletePlugin"}},c={},o=[{value:"Hierarchy",id:"hierarchy",level:2},{value:"Properties",id:"properties",level:2},{value:"execute",id:"execute",level:3},{value:"Type declaration",id:"type-declaration",level:4},{value:"Parameters",id:"parameters",level:5},{value:"Returns",id:"returns",level:5},{value:"Overrides",id:"overrides",level:4},{value:"Defined in",id:"defined-in",level:4},{value:"onEvent",id:"onevent",level:3},{value:"Overrides",id:"overrides-1",level:4},{value:"Defined in",id:"defined-in-1",level:4}];function a(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",h5:"h5",hr:"hr",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,i.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(n.h2,{id:"hierarchy",children:"Hierarchy"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.code,{children:"Omit"}),"<",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Module",children:(0,r.jsx)(n.code,{children:"Module"})}),", ",(0,r.jsx)(n.code,{children:'"name"'})," | ",(0,r.jsx)(n.code,{children:'"type"'})," | ",(0,r.jsx)(n.code,{children:'"plugins"'})," | ",(0,r.jsx)(n.code,{children:'"description"'}),">"]}),"\n",(0,r.jsxs)(n.p,{children:["\u21b3 ",(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"AutocompleteCommand"})})]}),"\n"]}),"\n"]}),"\n",(0,r.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,r.jsx)(n.h3,{id:"execute",children:"execute"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"execute"}),": (",(0,r.jsx)(n.code,{children:"ctx"}),": ",(0,r.jsx)(n.code,{children:"AutocompleteInteraction"}),"<",(0,r.jsx)(n.code,{children:"CacheType"}),">) => ",(0,r.jsx)(n.code,{children:"unknown"})]}),"\n",(0,r.jsx)(n.h4,{id:"type-declaration",children:"Type declaration"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 (",(0,r.jsx)(n.code,{children:"ctx"}),"): ",(0,r.jsx)(n.code,{children:"unknown"})]}),"\n",(0,r.jsx)(n.h5,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"ctx"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"AutocompleteInteraction"}),"<",(0,r.jsx)(n.code,{children:"CacheType"}),">"]})]})})]}),"\n",(0,r.jsx)(n.h5,{id:"returns",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"unknown"})}),"\n",(0,r.jsx)(n.h4,{id:"overrides",children:"Overrides"}),"\n",(0,r.jsx)(n.p,{children:"Omit.execute"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/types/module.ts#L111",children:"src/types/module.ts:111"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"onevent",children:"onEvent"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"onEvent"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/ControlPlugin",children:(0,r.jsx)(n.code,{children:"ControlPlugin"})}),"<",(0,r.jsx)(n.code,{children:"any"}),"[]>[]"]}),"\n",(0,r.jsx)(n.h4,{id:"overrides-1",children:"Overrides"}),"\n",(0,r.jsx)(n.p,{children:"Omit.onEvent"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/types/module.ts#L110",children:"src/types/module.ts:110"})})]})}function h(e={}){const{wrapper:n}={...(0,i.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(a,{...e})}):a(e)}},8453:(e,n,t)=>{t.d(n,{R:()=>l,x:()=>s});var r=t(6540);const i={},d=r.createContext(i);function l(e){const n=r.useContext(d);return r.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function s(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(i):e.components||i:l(e.components),r.createElement(d.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/814f3328.2f7d455e.js b/assets/js/814f3328.2f7d455e.js deleted file mode 100644 index ad7ac5836..000000000 --- a/assets/js/814f3328.2f7d455e.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[7472],{5513:e=>{e.exports=JSON.parse('{"title":"Recent posts","items":[{"title":"Deploying sern with Railway","permalink":"/blog/railway-deploy","unlisted":false},{"title":"New logo!","permalink":"/blog/newlogo","unlisted":false},{"title":"Release 3.0.0","permalink":"/blog/3.0.0","unlisted":false},{"title":"Release 2.5.0","permalink":"/blog/2.5.0","unlisted":false},{"title":"Release 2.0.0","permalink":"/blog/2.0.0","unlisted":false},{"title":"How to get started with sern!","permalink":"/blog/getting-started","unlisted":false},{"title":"Release 1.2.0","permalink":"/blog/1.2.0","unlisted":false}]}')}}]); \ No newline at end of file diff --git a/assets/js/82474f76.a3f2f6f9.js b/assets/js/82474f76.a3f2f6f9.js deleted file mode 100644 index 05cf44ee6..000000000 --- a/assets/js/82474f76.a3f2f6f9.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[1839],{1365:(e,t,n)=>{n.r(t),n.d(t,{assets:()=>c,contentTitle:()=>o,default:()=>u,frontMatter:()=>i,metadata:()=>a,toc:()=>l});var s=n(4848),r=n(8453);const i={},o=void 0,a={id:"cli/extra",title:"extra",description:"This command is pretty straightfoward. Install utilities into your application. Assumes you have a sern.config.json.",source:"@site/docs/cli/extra.md",sourceDirName:"cli",slug:"/cli/extra",permalink:"/docs/cli/extra",draft:!1,unlisted:!1,editUrl:"https://github.com/sern-handler/website/edit/main/docs/cli/extra.md",tags:[],version:"current",frontMatter:{},sidebar:"tutorialSidebar",previous:{title:"clear",permalink:"/docs/cli/clear"},next:{title:"publish",permalink:"/docs/cli/publish"}},c={},l=[];function d(e){const t={code:"code",p:"p",pre:"pre",...(0,r.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(t.pre,{children:(0,s.jsx)(t.code,{className:"language-sh",children:"Usage: sern extra [options]\n\nEasy way to add extra things in your sern project\n\nOptions:\n -h, --help display help for command\n"})}),"\n",(0,s.jsx)(t.p,{children:"This command is pretty straightfoward. Install utilities into your application. Assumes you have a sern.config.json."})]})}function u(e={}){const{wrapper:t}={...(0,r.R)(),...e.components};return t?(0,s.jsx)(t,{...e,children:(0,s.jsx)(d,{...e})}):d(e)}},8453:(e,t,n)=>{n.d(t,{R:()=>o,x:()=>a});var s=n(6540);const r={},i=s.createContext(r);function o(e){const t=s.useContext(i);return s.useMemo((function(){return"function"==typeof e?e(t):{...t,...e}}),[t,e])}function a(e){let t;return t=e.disableParentContext?"function"==typeof e.components?e.components(r):e.components||r:o(e.components),s.createElement(i.Provider,{value:t},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/82cdda05.dcdcf129.js b/assets/js/82cdda05.dcdcf129.js deleted file mode 100644 index 875a55e35..000000000 --- a/assets/js/82cdda05.dcdcf129.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[9392],{9673:(e,n,i)=>{i.r(n),i.d(n,{assets:()=>c,contentTitle:()=>l,default:()=>o,frontMatter:()=>s,metadata:()=>d,toc:()=>h});var t=i(4848),r=i(8453);const s={id:"EventPlugin",title:"Interface: EventPlugin ",sidebar_label:"EventPlugin",sidebar_position:0,custom_edit_url:null},l=void 0,d={id:"api/interfaces/EventPlugin",title:"Interface: EventPlugin ",description:"Deprecated",source:"@site/docs/api/interfaces/EventPlugin.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/EventPlugin",permalink:"/docs/api/interfaces/EventPlugin",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"EventPlugin",title:"Interface: EventPlugin ",sidebar_label:"EventPlugin",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"EventModuleDefs",permalink:"/docs/api/interfaces/EventModuleDefs"},next:{title:"ExternalEmitterPlugin",permalink:"/docs/api/interfaces/ExternalEmitterPlugin"}},c={},h=[{value:"Type parameters",id:"type-parameters",level:2},{value:"Properties",id:"properties",level:2},{value:"description",id:"description",level:3},{value:"Defined in",id:"defined-in",level:4},{value:"execute",id:"execute",level:3},{value:"Type declaration",id:"type-declaration",level:4},{value:"Parameters",id:"parameters",level:5},{value:"Returns",id:"returns",level:5},{value:"Defined in",id:"defined-in-1",level:4},{value:"name",id:"name",level:3},{value:"Defined in",id:"defined-in-2",level:4},{value:"type",id:"type",level:3},{value:"Defined in",id:"defined-in-3",level:4}];function a(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",h5:"h5",hr:"hr",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,r.R)(),...e.components};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(n.p,{children:(0,t.jsx)(n.strong,{children:(0,t.jsx)(n.code,{children:"Deprecated"})})}),"\n",(0,t.jsx)(n.p,{children:"Use the newer helper functions"}),"\n",(0,t.jsx)(n.h2,{id:"type-parameters",children:"Type parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,t.jsxs)(n.table,{children:[(0,t.jsx)(n.thead,{children:(0,t.jsxs)(n.tr,{children:[(0,t.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,t.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,t.jsx)(n.tbody,{children:(0,t.jsxs)(n.tr,{children:[(0,t.jsx)(n.td,{style:{textAlign:"left"},children:(0,t.jsx)(n.code,{children:"T"})}),(0,t.jsxs)(n.td,{style:{textAlign:"left"},children:["extends ",(0,t.jsx)(n.a,{href:"/docs/api/enums/CommandType",children:(0,t.jsx)(n.code,{children:"CommandType"})})]})]})})]}),"\n",(0,t.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,t.jsx)(n.h3,{id:"description",children:"description"}),"\n",(0,t.jsxs)(n.p,{children:["\u2022 ",(0,t.jsx)(n.code,{children:"Optional"})," ",(0,t.jsx)(n.strong,{children:"description"}),": ",(0,t.jsx)(n.code,{children:"string"})]}),"\n",(0,t.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,t.jsx)(n.p,{children:(0,t.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/types/plugin.ts#L64",children:"src/types/plugin.ts:64"})}),"\n",(0,t.jsx)(n.hr,{}),"\n",(0,t.jsx)(n.h3,{id:"execute",children:"execute"}),"\n",(0,t.jsxs)(n.p,{children:["\u2022 ",(0,t.jsx)(n.strong,{children:"execute"}),": (",(0,t.jsx)(n.code,{children:"args"}),": ",(0,t.jsx)(n.a,{href:"/docs/api/modules#commandargs",children:(0,t.jsx)(n.code,{children:"CommandArgs"})}),"<",(0,t.jsx)(n.code,{children:"T"}),", ",(0,t.jsx)(n.a,{href:"/docs/api/enums/PluginType#event",children:(0,t.jsx)(n.code,{children:"Event"})}),">, ",(0,t.jsx)(n.code,{children:"controller?"}),": ",(0,t.jsx)(n.a,{href:"/docs/api/interfaces/Controller",children:(0,t.jsx)(n.code,{children:"Controller"})}),") => ",(0,t.jsx)(n.a,{href:"/docs/api/modules#pluginresult",children:(0,t.jsx)(n.code,{children:"PluginResult"})})]}),"\n",(0,t.jsx)(n.h4,{id:"type-declaration",children:"Type declaration"}),"\n",(0,t.jsxs)(n.p,{children:["\u25b8 (",(0,t.jsx)(n.code,{children:"args"}),", ",(0,t.jsx)(n.code,{children:"controller?"}),"): ",(0,t.jsx)(n.a,{href:"/docs/api/modules#pluginresult",children:(0,t.jsx)(n.code,{children:"PluginResult"})})]}),"\n",(0,t.jsx)(n.h5,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,t.jsxs)(n.table,{children:[(0,t.jsx)(n.thead,{children:(0,t.jsxs)(n.tr,{children:[(0,t.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,t.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,t.jsxs)(n.tbody,{children:[(0,t.jsxs)(n.tr,{children:[(0,t.jsx)(n.td,{style:{textAlign:"left"},children:(0,t.jsx)(n.code,{children:"args"})}),(0,t.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,t.jsx)(n.a,{href:"/docs/api/modules#commandargs",children:(0,t.jsx)(n.code,{children:"CommandArgs"})}),"<",(0,t.jsx)(n.code,{children:"T"}),", ",(0,t.jsx)(n.a,{href:"/docs/api/enums/PluginType#event",children:(0,t.jsx)(n.code,{children:"Event"})}),">"]})]}),(0,t.jsxs)(n.tr,{children:[(0,t.jsx)(n.td,{style:{textAlign:"left"},children:(0,t.jsx)(n.code,{children:"controller?"})}),(0,t.jsx)(n.td,{style:{textAlign:"left"},children:(0,t.jsx)(n.a,{href:"/docs/api/interfaces/Controller",children:(0,t.jsx)(n.code,{children:"Controller"})})})]})]})]}),"\n",(0,t.jsx)(n.h5,{id:"returns",children:"Returns"}),"\n",(0,t.jsx)(n.p,{children:(0,t.jsx)(n.a,{href:"/docs/api/modules#pluginresult",children:(0,t.jsx)(n.code,{children:"PluginResult"})})}),"\n",(0,t.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,t.jsx)(n.p,{children:(0,t.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/types/plugin.ts#L66",children:"src/types/plugin.ts:66"})}),"\n",(0,t.jsx)(n.hr,{}),"\n",(0,t.jsx)(n.h3,{id:"name",children:"name"}),"\n",(0,t.jsxs)(n.p,{children:["\u2022 ",(0,t.jsx)(n.code,{children:"Optional"})," ",(0,t.jsx)(n.strong,{children:"name"}),": ",(0,t.jsx)(n.code,{children:"string"})]}),"\n",(0,t.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,t.jsx)(n.p,{children:(0,t.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/types/plugin.ts#L63",children:"src/types/plugin.ts:63"})}),"\n",(0,t.jsx)(n.hr,{}),"\n",(0,t.jsx)(n.h3,{id:"type",children:"type"}),"\n",(0,t.jsxs)(n.p,{children:["\u2022 ",(0,t.jsx)(n.strong,{children:"type"}),": ",(0,t.jsx)(n.a,{href:"/docs/api/enums/PluginType#event",children:(0,t.jsx)(n.code,{children:"Event"})})]}),"\n",(0,t.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,t.jsx)(n.p,{children:(0,t.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/types/plugin.ts#L65",children:"src/types/plugin.ts:65"})})]})}function o(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,t.jsx)(n,{...e,children:(0,t.jsx)(a,{...e})}):a(e)}},8453:(e,n,i)=>{i.d(n,{R:()=>l,x:()=>d});var t=i(6540);const r={},s=t.createContext(r);function l(e){const n=t.useContext(s);return t.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function d(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(r):e.components||r:l(e.components),t.createElement(s.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/83d480e9.6fc38056.js b/assets/js/83d480e9.6fc38056.js deleted file mode 100644 index 628a00776..000000000 --- a/assets/js/83d480e9.6fc38056.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[9650],{4078:e=>{e.exports=JSON.parse('{"label":"release","permalink":"/blog/tags/release","allTagsPath":"/blog/tags","count":4,"unlisted":false}')}}]); \ No newline at end of file diff --git a/assets/js/85456a26.e1958609.js b/assets/js/85456a26.e1958609.js deleted file mode 100644 index 213ceb36a..000000000 --- a/assets/js/85456a26.e1958609.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[8036],{575:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>a,contentTitle:()=>d,default:()=>h,frontMatter:()=>i,metadata:()=>l,toc:()=>c});var r=t(4848),s=t(8453);const i={id:"InitArgs",title:"Interface: InitArgs ",sidebar_label:"InitArgs",sidebar_position:0,custom_edit_url:null},d=void 0,l={id:"api/interfaces/InitArgs",title:"Interface: InitArgs ",description:"Type parameters",source:"@site/docs/api/interfaces/InitArgs.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/InitArgs",permalink:"/docs/api/interfaces/InitArgs",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"InitArgs",title:"Interface: InitArgs ",sidebar_label:"InitArgs",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"Init",permalink:"/docs/api/interfaces/Init"},next:{title:"InitPlugin",permalink:"/docs/api/interfaces/InitPlugin"}},a={},c=[{value:"Type parameters",id:"type-parameters",level:2},{value:"Properties",id:"properties",level:2},{value:"absPath",id:"abspath",level:3},{value:"Defined in",id:"defined-in",level:4},{value:"module",id:"module",level:3},{value:"Defined in",id:"defined-in-1",level:4}];function o(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",hr:"hr",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,s.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(n.h2,{id:"type-parameters",children:"Type parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"T"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["extends ",(0,r.jsx)(n.a,{href:"/docs/api/modules#processed",children:(0,r.jsx)(n.code,{children:"Processed"})}),"<",(0,r.jsx)(n.a,{href:"Module.md",children:(0,r.jsx)(n.code,{children:"Module"})}),">"]})]})})]}),"\n",(0,r.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,r.jsx)(n.h3,{id:"abspath",children:"absPath"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"absPath"}),": ",(0,r.jsx)(n.code,{children:"string"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/handler/plugins/args.ts#L107",children:"src/handler/plugins/args.ts:107"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"module",children:"module"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"module"}),": ",(0,r.jsx)(n.code,{children:"T"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/handler/plugins/args.ts#L106",children:"src/handler/plugins/args.ts:106"})})]})}function h(e={}){const{wrapper:n}={...(0,s.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(o,{...e})}):o(e)}},8453:(e,n,t)=>{t.d(n,{R:()=>d,x:()=>l});var r=t(6540);const s={},i=r.createContext(s);function d(e){const n=r.useContext(i);return r.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function l(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:d(e.components),r.createElement(i.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/8645.5bf758dc.js b/assets/js/8645.5bf758dc.js deleted file mode 100644 index 77fd75fa9..000000000 --- a/assets/js/8645.5bf758dc.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[8645],{7293:(n,e,t)=>{t.d(e,{A:()=>_});var i=t(6540),s=t(4848);function o(n){const{mdxAdmonitionTitle:e,rest:t}=function(n){const e=i.Children.toArray(n),t=e.find((n=>i.isValidElement(n)&&"mdxAdmonitionTitle"===n.type)),o=e.filter((n=>n!==t)),a=t?.props.children;return{mdxAdmonitionTitle:a,rest:o.length>0?(0,s.jsx)(s.Fragment,{children:o}):null}}(n.children),o=n.title??e;return{...n,...o&&{title:o},children:t}}var a=t(53),l=t(1312),r=t(7559);const c={admonition:"admonition_xJq3",admonitionHeading:"admonitionHeading_Gvgb",admonitionIcon:"admonitionIcon_Rf37",admonitionContent:"admonitionContent_BuS1"};function d(n){let{type:e,className:t,children:i}=n;return(0,s.jsx)("div",{className:(0,a.A)(r.G.common.admonition,r.G.common.admonitionType(e),c.admonition,t),children:i})}function u(n){let{icon:e,title:t}=n;return(0,s.jsxs)("div",{className:c.admonitionHeading,children:[(0,s.jsx)("span",{className:c.admonitionIcon,children:e}),t]})}function m(n){let{children:e}=n;return e?(0,s.jsx)("div",{className:c.admonitionContent,children:e}):null}function h(n){const{type:e,icon:t,title:i,children:o,className:a}=n;return(0,s.jsxs)(d,{type:e,className:a,children:[(0,s.jsx)(u,{title:i,icon:t}),(0,s.jsx)(m,{children:o})]})}function f(n){return(0,s.jsx)("svg",{viewBox:"0 0 14 16",...n,children:(0,s.jsx)("path",{fillRule:"evenodd",d:"M6.3 5.69a.942.942 0 0 1-.28-.7c0-.28.09-.52.28-.7.19-.18.42-.28.7-.28.28 0 .52.09.7.28.18.19.28.42.28.7 0 .28-.09.52-.28.7a1 1 0 0 1-.7.3c-.28 0-.52-.11-.7-.3zM8 7.99c-.02-.25-.11-.48-.31-.69-.2-.19-.42-.3-.69-.31H6c-.27.02-.48.13-.69.31-.2.2-.3.44-.31.69h1v3c.02.27.11.5.31.69.2.2.42.31.69.31h1c.27 0 .48-.11.69-.31.2-.19.3-.42.31-.69H8V7.98v.01zM7 2.3c-3.14 0-5.7 2.54-5.7 5.68 0 3.14 2.56 5.7 5.7 5.7s5.7-2.55 5.7-5.7c0-3.15-2.56-5.69-5.7-5.69v.01zM7 .98c3.86 0 7 3.14 7 7s-3.14 7-7 7-7-3.12-7-7 3.14-7 7-7z"})})}const x={icon:(0,s.jsx)(f,{}),title:(0,s.jsx)(l.A,{id:"theme.admonition.note",description:"The default label used for the Note admonition (:::note)",children:"note"})};function j(n){return(0,s.jsx)(h,{...x,...n,className:(0,a.A)("alert alert--secondary",n.className),children:n.children})}function p(n){return(0,s.jsx)("svg",{viewBox:"0 0 12 16",...n,children:(0,s.jsx)("path",{fillRule:"evenodd",d:"M6.5 0C3.48 0 1 2.19 1 5c0 .92.55 2.25 1 3 1.34 2.25 1.78 2.78 2 4v1h5v-1c.22-1.22.66-1.75 2-4 .45-.75 1-2.08 1-3 0-2.81-2.48-5-5.5-5zm3.64 7.48c-.25.44-.47.8-.67 1.11-.86 1.41-1.25 2.06-1.45 3.23-.02.05-.02.11-.02.17H5c0-.06 0-.13-.02-.17-.2-1.17-.59-1.83-1.45-3.23-.2-.31-.42-.67-.67-1.11C2.44 6.78 2 5.65 2 5c0-2.2 2.02-4 4.5-4 1.22 0 2.36.42 3.22 1.19C10.55 2.94 11 3.94 11 5c0 .66-.44 1.78-.86 2.48zM4 14h5c-.23 1.14-1.3 2-2.5 2s-2.27-.86-2.5-2z"})})}const v={icon:(0,s.jsx)(p,{}),title:(0,s.jsx)(l.A,{id:"theme.admonition.tip",description:"The default label used for the Tip admonition (:::tip)",children:"tip"})};function g(n){return(0,s.jsx)(h,{...v,...n,className:(0,a.A)("alert alert--success",n.className),children:n.children})}function A(n){return(0,s.jsx)("svg",{viewBox:"0 0 14 16",...n,children:(0,s.jsx)("path",{fillRule:"evenodd",d:"M7 2.3c3.14 0 5.7 2.56 5.7 5.7s-2.56 5.7-5.7 5.7A5.71 5.71 0 0 1 1.3 8c0-3.14 2.56-5.7 5.7-5.7zM7 1C3.14 1 0 4.14 0 8s3.14 7 7 7 7-3.14 7-7-3.14-7-7-7zm1 3H6v5h2V4zm0 6H6v2h2v-2z"})})}const N={icon:(0,s.jsx)(A,{}),title:(0,s.jsx)(l.A,{id:"theme.admonition.info",description:"The default label used for the Info admonition (:::info)",children:"info"})};function y(n){return(0,s.jsx)(h,{...N,...n,className:(0,a.A)("alert alert--info",n.className),children:n.children})}function C(n){return(0,s.jsx)("svg",{viewBox:"0 0 16 16",...n,children:(0,s.jsx)("path",{fillRule:"evenodd",d:"M8.893 1.5c-.183-.31-.52-.5-.887-.5s-.703.19-.886.5L.138 13.499a.98.98 0 0 0 0 1.001c.193.31.53.501.886.501h13.964c.367 0 .704-.19.877-.5a1.03 1.03 0 0 0 .01-1.002L8.893 1.5zm.133 11.497H6.987v-2.003h2.039v2.003zm0-3.004H6.987V5.987h2.039v4.006z"})})}const b={icon:(0,s.jsx)(C,{}),title:(0,s.jsx)(l.A,{id:"theme.admonition.warning",description:"The default label used for the Warning admonition (:::warning)",children:"warning"})};function w(n){return(0,s.jsx)("svg",{viewBox:"0 0 12 16",...n,children:(0,s.jsx)("path",{fillRule:"evenodd",d:"M5.05.31c.81 2.17.41 3.38-.52 4.31C3.55 5.67 1.98 6.45.9 7.98c-1.45 2.05-1.7 6.53 3.53 7.7-2.2-1.16-2.67-4.52-.3-6.61-.61 2.03.53 3.33 1.94 2.86 1.39-.47 2.3.53 2.27 1.67-.02.78-.31 1.44-1.13 1.81 3.42-.59 4.78-3.42 4.78-5.56 0-2.84-2.53-3.22-1.25-5.61-1.52.13-2.03 1.13-1.89 2.75.09 1.08-1.02 1.8-1.86 1.33-.67-.41-.66-1.19-.06-1.78C8.18 5.31 8.68 2.45 5.05.32L5.03.3l.02.01z"})})}const z={icon:(0,s.jsx)(w,{}),title:(0,s.jsx)(l.A,{id:"theme.admonition.danger",description:"The default label used for the Danger admonition (:::danger)",children:"danger"})};const T={icon:(0,s.jsx)(C,{}),title:(0,s.jsx)(l.A,{id:"theme.admonition.caution",description:"The default label used for the Caution admonition (:::caution)",children:"caution"})};const M={...{note:j,tip:g,info:y,warning:function(n){return(0,s.jsx)(h,{...b,...n,className:(0,a.A)("alert alert--warning",n.className),children:n.children})},danger:function(n){return(0,s.jsx)(h,{...z,...n,className:(0,a.A)("alert alert--danger",n.className),children:n.children})}},...{secondary:n=>(0,s.jsx)(j,{title:"secondary",...n}),important:n=>(0,s.jsx)(y,{title:"important",...n}),success:n=>(0,s.jsx)(g,{title:"success",...n}),caution:function(n){return(0,s.jsx)(h,{...T,...n,className:(0,a.A)("alert alert--warning",n.className),children:n.children})}}};function _(n){const e=o(n),t=(i=e.type,M[i]||(console.warn(`No admonition component found for admonition type "${i}". Using Info as fallback.`),M.info));var i;return(0,s.jsx)(t,{...e})}},8645:(n,e,t)=>{t.d(e,{A:()=>T});var i=t(6540),s=t(8453),o=t(5260),a=t(4428),l=t(4848);var r=t(5489);var c=t(53),d=t(2303),u=t(1422);const m={details:"details_lb9f",isBrowser:"isBrowser_bmU9",collapsibleContent:"collapsibleContent_i85q"};function h(n){return!!n&&("SUMMARY"===n.tagName||h(n.parentElement))}function f(n,e){return!!n&&(n===e||f(n.parentElement,e))}function x(n){let{summary:e,children:t,...s}=n;const o=(0,d.A)(),a=(0,i.useRef)(null),{collapsed:r,setCollapsed:x}=(0,u.u)({initialState:!s.open}),[j,p]=(0,i.useState)(s.open),v=i.isValidElement(e)?e:(0,l.jsx)("summary",{children:e??"Details"});return(0,l.jsxs)("details",{...s,ref:a,open:j,"data-collapsed":r,className:(0,c.A)(m.details,o&&m.isBrowser,s.className),onMouseDown:n=>{h(n.target)&&n.detail>1&&n.preventDefault()},onClick:n=>{n.stopPropagation();const e=n.target;h(e)&&f(e,a.current)&&(n.preventDefault(),r?(x(!1),p(!0)):x(!0))},children:[v,(0,l.jsx)(u.N,{lazy:!1,collapsed:r,disableSSRStyle:!0,onCollapseTransitionEnd:n=>{x(n),p(!n)},children:(0,l.jsx)("div",{className:m.collapsibleContent,children:t})})]})}const j={details:"details_b_Ee"},p="alert alert--info";function v(n){let{...e}=n;return(0,l.jsx)(x,{...e,className:(0,c.A)(p,j.details,e.className)})}function g(n){const e=i.Children.toArray(n.children),t=e.find((n=>i.isValidElement(n)&&"summary"===n.type)),s=(0,l.jsx)(l.Fragment,{children:e.filter((n=>n!==t))});return(0,l.jsx)(v,{...n,summary:t,children:s})}var A=t(1107);function N(n){return(0,l.jsx)(A.A,{...n})}const y={containsTaskList:"containsTaskList_mC6p"};function C(n){if(void 0!==n)return(0,c.A)(n,n?.includes("contains-task-list")&&y.containsTaskList)}const b={img:"img_ev3q"};var w=t(7293);const z={Head:o.A,details:g,Details:g,code:function(n){return i.Children.toArray(n.children).every((n=>"string"==typeof n&&!n.includes("\n")))?(0,l.jsx)("code",{...n}):(0,l.jsx)(a.A,{...n})},a:function(n){return(0,l.jsx)(r.A,{...n})},pre:function(n){return(0,l.jsx)(l.Fragment,{children:n.children})},ul:function(n){return(0,l.jsx)("ul",{...n,className:C(n.className)})},img:function(n){return(0,l.jsx)("img",{loading:"lazy",...n,className:(e=n.className,(0,c.A)(e,b.img))});var e},h1:n=>(0,l.jsx)(N,{as:"h1",...n}),h2:n=>(0,l.jsx)(N,{as:"h2",...n}),h3:n=>(0,l.jsx)(N,{as:"h3",...n}),h4:n=>(0,l.jsx)(N,{as:"h4",...n}),h5:n=>(0,l.jsx)(N,{as:"h5",...n}),h6:n=>(0,l.jsx)(N,{as:"h6",...n}),admonition:w.A,mermaid:()=>null};function T(n){let{children:e}=n;return(0,l.jsx)(s.x,{components:z,children:e})}},8453:(n,e,t)=>{t.d(e,{R:()=>a,x:()=>l});var i=t(6540);const s={},o=i.createContext(s);function a(n){const e=i.useContext(o);return i.useMemo((function(){return"function"==typeof n?n(e):{...e,...n}}),[e,n])}function l(n){let e;return e=n.disableParentContext?"function"==typeof n.components?n.components(s):n.components||s:a(n.components),i.createElement(o.Provider,{value:e},n.children)}}}]); \ No newline at end of file diff --git a/assets/js/86b8ce54.3f8ce513.js b/assets/js/86b8ce54.3f8ce513.js deleted file mode 100644 index cfac3f663..000000000 --- a/assets/js/86b8ce54.3f8ce513.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[9856],{4941:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>a,contentTitle:()=>i,default:()=>p,frontMatter:()=>r,metadata:()=>c,toc:()=>l});var o=t(4848),s=t(8453);const r={},i="CLI",c={id:"cli/README",title:"CLI",description:"Publish commands to the API, install plugins, and use other tools provided by our cli.",source:"@site/docs/cli/README.md",sourceDirName:"cli",slug:"/cli/",permalink:"/docs/cli/",draft:!1,unlisted:!1,editUrl:"https://github.com/sern-handler/website/edit/main/docs/cli/README.md",tags:[],version:"current",frontMatter:{},sidebar:"tutorialSidebar",previous:{title:"Welcome!",permalink:"/docs/intro"},next:{title:"build",permalink:"/docs/cli/build"}},a={},l=[];function d(e){const n={code:"code",h1:"h1",p:"p",pre:"pre",...(0,s.R)(),...e.components};return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(n.h1,{id:"cli",children:"CLI"}),"\n",(0,o.jsx)(n.p,{children:"Publish commands to the API, install plugins, and use other tools provided by our cli."}),"\n",(0,o.jsx)(n.p,{children:"The CLI is your pocketknife for discord bot development. It'll have all features necessary for developing and shipping to production."}),"\n",(0,o.jsx)(n.pre,{children:(0,o.jsx)(n.code,{children:"Usage: sern [options] [command]\n\n\n ___ ___ _ __ _ __\n / __|/ _ \\ '__| '_ \\\n \\__ \\ __/ | | | | |\n |___/\\___|_| |_| |_|\n\n Welcome!\n If you're new to sern, run npm create @sern/bot for an interactive setup to your new bot project!\n\n If you have any ideas, suggestions, bug reports, kindly join our support server: https://sern.dev/discord\n\nOptions:\n -v, --version output the version number\n -h, --help display help for command\n\nCommands:\n init [options] Quickest way to scaffold a new project [DEPRECATED]\n plugins [options] Install plugins from https://github.com/sern-handler/awesome-plugins\n extra Easy way to add extra things in your sern project\n commands Defacto way to manage your slash commands\n help [command] display help for command\n"})})]})}function p(e={}){const{wrapper:n}={...(0,s.R)(),...e.components};return n?(0,o.jsx)(n,{...e,children:(0,o.jsx)(d,{...e})}):d(e)}},8453:(e,n,t)=>{t.d(n,{R:()=>i,x:()=>c});var o=t(6540);const s={},r=o.createContext(s);function i(e){const n=o.useContext(r);return o.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function c(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:i(e.components),o.createElement(r.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/8747.34a2c022.js b/assets/js/8747.34a2c022.js deleted file mode 100644 index d279ca463..000000000 --- a/assets/js/8747.34a2c022.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[8747],{6535:(e,t,s)=>{s.d(t,{A:()=>f});var a=s(6540),n=s(53),r=s(8511),l=s(4581),i=s(5489),o=s(1312),c=s(6347),m=s(9169);function d(e){const{pathname:t}=(0,c.zy)();return(0,a.useMemo)((()=>e.filter((e=>function(e,t){return!(e.unlisted&&!(0,m.ys)(e.permalink,t))}(e,t)))),[e,t])}const u={sidebar:"sidebar_re4s",sidebarItemTitle:"sidebarItemTitle_pO2u",sidebarItemList:"sidebarItemList_Yudw",sidebarItem:"sidebarItem__DBe",sidebarItemLink:"sidebarItemLink_mo7H",sidebarItemLinkActive:"sidebarItemLinkActive_I1ZP"};var h=s(4848);function g(e){let{sidebar:t}=e;const s=d(t.items);return(0,h.jsx)("aside",{className:"col col--3",children:(0,h.jsxs)("nav",{className:(0,n.A)(u.sidebar,"thin-scrollbar"),"aria-label":(0,o.T)({id:"theme.blog.sidebar.navAriaLabel",message:"Blog recent posts navigation",description:"The ARIA label for recent posts in the blog sidebar"}),children:[(0,h.jsx)("div",{className:(0,n.A)(u.sidebarItemTitle,"margin-bottom--md"),children:t.title}),(0,h.jsx)("ul",{className:(0,n.A)(u.sidebarItemList,"clean-list"),children:s.map((e=>(0,h.jsx)("li",{className:u.sidebarItem,children:(0,h.jsx)(i.A,{isNavLink:!0,to:e.permalink,className:u.sidebarItemLink,activeClassName:u.sidebarItemLinkActive,children:e.title})},e.permalink)))})]})})}var p=s(5600);function x(e){let{sidebar:t}=e;const s=d(t.items);return(0,h.jsx)("ul",{className:"menu__list",children:s.map((e=>(0,h.jsx)("li",{className:"menu__list-item",children:(0,h.jsx)(i.A,{isNavLink:!0,to:e.permalink,className:"menu__link",activeClassName:"menu__link--active",children:e.title})},e.permalink)))})}function j(e){return(0,h.jsx)(p.GX,{component:x,props:e})}function b(e){let{sidebar:t}=e;const s=(0,l.l)();return t?.items.length?"mobile"===s?(0,h.jsx)(j,{sidebar:t}):(0,h.jsx)(g,{sidebar:t}):null}function f(e){const{sidebar:t,toc:s,children:a,...l}=e,i=t&&t.items.length>0;return(0,h.jsx)(r.A,{...l,children:(0,h.jsx)("div",{className:"container margin-vert--lg",children:(0,h.jsxs)("div",{className:"row",children:[(0,h.jsx)(b,{sidebar:t}),(0,h.jsx)("main",{className:(0,n.A)("col",{"col--7":i,"col--9 col--offset-1":!i}),itemScope:!0,itemType:"https://schema.org/Blog",children:a}),s&&(0,h.jsx)("div",{className:"col col--2",children:s})]})})})}},8258:(e,t,s)=>{s.d(t,{A:()=>C});s(6540);var a=s(53),n=s(7131),r=s(6025),l=s(4848);function i(e){let{children:t,className:s}=e;const{frontMatter:a,assets:i,metadata:{description:o}}=(0,n.e)(),{withBaseUrl:c}=(0,r.h)(),m=i.image??a.image,d=a.keywords??[];return(0,l.jsxs)("article",{className:s,itemProp:"blogPost",itemScope:!0,itemType:"https://schema.org/BlogPosting",children:[o&&(0,l.jsx)("meta",{itemProp:"description",content:o}),m&&(0,l.jsx)("link",{itemProp:"image",href:c(m,{absolute:!0})}),d.length>0&&(0,l.jsx)("meta",{itemProp:"keywords",content:d.join(",")}),t]})}var o=s(5489);const c={title:"title_f1Hy"};function m(e){let{className:t}=e;const{metadata:s,isBlogPostPage:r}=(0,n.e)(),{permalink:i,title:m}=s,d=r?"h1":"h2";return(0,l.jsx)(d,{className:(0,a.A)(c.title,t),itemProp:"headline",children:r?m:(0,l.jsx)(o.A,{itemProp:"url",to:i,children:m})})}var d=s(1312),u=s(5846);const h={container:"container_mt6G"};function g(e){let{readingTime:t}=e;const s=function(){const{selectMessage:e}=(0,u.W)();return t=>{const s=Math.ceil(t);return e(s,(0,d.T)({id:"theme.blog.post.readingTime.plurals",description:'Pluralized label for "{readingTime} min read". Use as much plural forms (separated by "|") as your language support (see https://www.unicode.org/cldr/cldr-aux/charts/34/supplemental/language_plural_rules.html)',message:"One min read|{readingTime} min read"},{readingTime:s}))}}();return(0,l.jsx)(l.Fragment,{children:s(t)})}function p(e){let{date:t,formattedDate:s}=e;return(0,l.jsx)("time",{dateTime:t,itemProp:"datePublished",children:s})}function x(){return(0,l.jsx)(l.Fragment,{children:" \xb7 "})}function j(e){let{className:t}=e;const{metadata:s}=(0,n.e)(),{date:r,formattedDate:i,readingTime:o}=s;return(0,l.jsxs)("div",{className:(0,a.A)(h.container,"margin-vert--md",t),children:[(0,l.jsx)(p,{date:r,formattedDate:i}),void 0!==o&&(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(x,{}),(0,l.jsx)(g,{readingTime:o})]})]})}function b(e){return e.href?(0,l.jsx)(o.A,{...e}):(0,l.jsx)(l.Fragment,{children:e.children})}function f(e){let{author:t,className:s}=e;const{name:n,title:r,url:i,imageURL:o,email:c}=t,m=i||c&&`mailto:${c}`||void 0;return(0,l.jsxs)("div",{className:(0,a.A)("avatar margin-bottom--sm",s),children:[o&&(0,l.jsx)(b,{href:m,className:"avatar__photo-link",children:(0,l.jsx)("img",{className:"avatar__photo",src:o,alt:n,itemProp:"image"})}),n&&(0,l.jsxs)("div",{className:"avatar__intro",itemProp:"author",itemScope:!0,itemType:"https://schema.org/Person",children:[(0,l.jsx)("div",{className:"avatar__name",children:(0,l.jsx)(b,{href:m,itemProp:"url",children:(0,l.jsx)("span",{itemProp:"name",children:n})})}),r&&(0,l.jsx)("small",{className:"avatar__subtitle",itemProp:"description",children:r})]})]})}const v={authorCol:"authorCol_Hf19",imageOnlyAuthorRow:"imageOnlyAuthorRow_pa_O",imageOnlyAuthorCol:"imageOnlyAuthorCol_G86a"};function A(e){let{className:t}=e;const{metadata:{authors:s},assets:r}=(0,n.e)();if(0===s.length)return null;const i=s.every((e=>{let{name:t}=e;return!t}));return(0,l.jsx)("div",{className:(0,a.A)("margin-top--md margin-bottom--sm",i?v.imageOnlyAuthorRow:"row",t),children:s.map(((e,t)=>(0,l.jsx)("div",{className:(0,a.A)(!i&&"col col--6",i?v.imageOnlyAuthorCol:v.authorCol),children:(0,l.jsx)(f,{author:{...e,imageURL:r.authorsImageUrls[t]??e.imageURL}})},t)))})}function _(){return(0,l.jsxs)("header",{children:[(0,l.jsx)(m,{}),(0,l.jsx)(j,{}),(0,l.jsx)(A,{})]})}var N=s(440),P=s(8645);function k(e){let{children:t,className:s}=e;const{isBlogPostPage:r}=(0,n.e)();return(0,l.jsx)("div",{id:r?N.blogPostContainerID:void 0,className:(0,a.A)("markdown",s),itemProp:"articleBody",children:(0,l.jsx)(P.A,{children:t})})}var T=s(1943),w=s(2053);function I(){return(0,l.jsx)("b",{children:(0,l.jsx)(d.A,{id:"theme.blog.post.readMore",description:"The label used in blog post item excerpts to link to full blog posts",children:"Read More"})})}function y(e){const{blogPostTitle:t,...s}=e;return(0,l.jsx)(o.A,{"aria-label":(0,d.T)({message:"Read more about {title}",id:"theme.blog.post.readMoreLabel",description:"The ARIA label for the link to full blog posts from excerpts"},{title:t}),...s,children:(0,l.jsx)(I,{})})}const F={blogPostFooterDetailsFull:"blogPostFooterDetailsFull_mRVl"};function L(){const{metadata:e,isBlogPostPage:t}=(0,n.e)(),{tags:s,title:r,editUrl:i,hasTruncateMarker:o}=e,c=!t&&o,m=s.length>0;return m||c||i?(0,l.jsxs)("footer",{className:(0,a.A)("row docusaurus-mt-lg",t&&F.blogPostFooterDetailsFull),children:[m&&(0,l.jsx)("div",{className:(0,a.A)("col",{"col--9":c}),children:(0,l.jsx)(w.A,{tags:s})}),t&&i&&(0,l.jsx)("div",{className:"col margin-top--sm",children:(0,l.jsx)(T.A,{editUrl:i})}),c&&(0,l.jsx)("div",{className:(0,a.A)("col text--right",{"col--3":m}),children:(0,l.jsx)(y,{blogPostTitle:r,to:e.permalink})})]}):null}function C(e){let{children:t,className:s}=e;const r=function(){const{isBlogPostPage:e}=(0,n.e)();return e?void 0:"margin-bottom--xl"}();return(0,l.jsxs)(i,{className:(0,a.A)(r,s),children:[(0,l.jsx)(_,{}),(0,l.jsx)(k,{children:t}),(0,l.jsx)(L,{})]})}},1943:(e,t,s)=>{s.d(t,{A:()=>m});s(6540);var a=s(1312),n=s(7559),r=s(5489),l=s(53);const i={iconEdit:"iconEdit_Z9Sw"};var o=s(4848);function c(e){let{className:t,...s}=e;return(0,o.jsx)("svg",{fill:"currentColor",height:"20",width:"20",viewBox:"0 0 40 40",className:(0,l.A)(i.iconEdit,t),"aria-hidden":"true",...s,children:(0,o.jsx)("g",{children:(0,o.jsx)("path",{d:"m34.5 11.7l-3 3.1-6.3-6.3 3.1-3q0.5-0.5 1.2-0.5t1.1 0.5l3.9 3.9q0.5 0.4 0.5 1.1t-0.5 1.2z m-29.5 17.1l18.4-18.5 6.3 6.3-18.4 18.4h-6.3v-6.2z"})})})}function m(e){let{editUrl:t}=e;return(0,o.jsxs)(r.A,{to:t,className:n.G.common.editThisPage,children:[(0,o.jsx)(c,{}),(0,o.jsx)(a.A,{id:"theme.common.editThisPage",description:"The link label to edit the current page",children:"Edit this page"})]})}},9022:(e,t,s)=>{s.d(t,{A:()=>l});s(6540);var a=s(53),n=s(5489),r=s(4848);function l(e){const{permalink:t,title:s,subLabel:l,isNext:i}=e;return(0,r.jsxs)(n.A,{className:(0,a.A)("pagination-nav__link",i?"pagination-nav__link--next":"pagination-nav__link--prev"),to:t,children:[l&&(0,r.jsx)("div",{className:"pagination-nav__sublabel",children:l}),(0,r.jsx)("div",{className:"pagination-nav__label",children:s})]})}},6133:(e,t,s)=>{s.d(t,{A:()=>i});s(6540);var a=s(53),n=s(5489);const r={tag:"tag_zVej",tagRegular:"tagRegular_sFm0",tagWithCount:"tagWithCount_h2kH"};var l=s(4848);function i(e){let{permalink:t,label:s,count:i}=e;return(0,l.jsxs)(n.A,{href:t,className:(0,a.A)(r.tag,i?r.tagWithCount:r.tagRegular),children:[s,i&&(0,l.jsx)("span",{children:i})]})}},2053:(e,t,s)=>{s.d(t,{A:()=>o});s(6540);var a=s(53),n=s(1312),r=s(6133);const l={tags:"tags_jXut",tag:"tag_QGVx"};var i=s(4848);function o(e){let{tags:t}=e;return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)("b",{children:(0,i.jsx)(n.A,{id:"theme.tags.tagsListLabel",description:"The label alongside a tag list",children:"Tags:"})}),(0,i.jsx)("ul",{className:(0,a.A)(l.tags,"padding--none","margin-left--sm"),children:t.map((e=>{let{label:t,permalink:s}=e;return(0,i.jsx)("li",{className:l.tag,children:(0,i.jsx)(r.A,{label:t,permalink:s})},s)}))})]})}},7131:(e,t,s)=>{s.d(t,{e:()=>o,i:()=>i});var a=s(6540),n=s(9532),r=s(4848);const l=a.createContext(null);function i(e){let{children:t,content:s,isBlogPostPage:n=!1}=e;const i=function(e){let{content:t,isBlogPostPage:s}=e;return(0,a.useMemo)((()=>({metadata:t.metadata,frontMatter:t.frontMatter,assets:t.assets,toc:t.toc,isBlogPostPage:s})),[t,s])}({content:s,isBlogPostPage:n});return(0,r.jsx)(l.Provider,{value:i,children:t})}function o(){const e=(0,a.useContext)(l);if(null===e)throw new n.dV("BlogPostProvider");return e}},5846:(e,t,s)=>{s.d(t,{W:()=>c});var a=s(6540),n=s(4586);const r=["zero","one","two","few","many","other"];function l(e){return r.filter((t=>e.includes(t)))}const i={locale:"en",pluralForms:l(["one","other"]),select:e=>1===e?"one":"other"};function o(){const{i18n:{currentLocale:e}}=(0,n.A)();return(0,a.useMemo)((()=>{try{return function(e){const t=new Intl.PluralRules(e);return{locale:e,pluralForms:l(t.resolvedOptions().pluralCategories),select:e=>t.select(e)}}(e)}catch(t){return console.error(`Failed to use Intl.PluralRules for locale "${e}".\nDocusaurus will fallback to the default (English) implementation.\nError: ${t.message}\n`),i}}),[e])}function c(){const e=o();return{selectMessage:(t,s)=>function(e,t,s){const a=e.split("|");if(1===a.length)return a[0];a.length>s.pluralForms.length&&console.error(`For locale=${s.locale}, a maximum of ${s.pluralForms.length} plural forms are expected (${s.pluralForms.join(",")}), but the message contains ${a.length}: ${e}`);const n=s.select(t),r=s.pluralForms.indexOf(n);return a[Math.min(r,a.length-1)]}(s,t,e)}}}}]); \ No newline at end of file diff --git a/assets/js/887ace0c.daabf20c.js b/assets/js/887ace0c.daabf20c.js deleted file mode 100644 index c61968367..000000000 --- a/assets/js/887ace0c.daabf20c.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[8820],{8778:(e,n,s)=>{s.r(n),s.d(n,{assets:()=>l,contentTitle:()=>d,default:()=>o,frontMatter:()=>t,metadata:()=>c,toc:()=>a});var r=s(4848),i=s(8453);const t={id:"Presence.Result",title:"Interface: Result",sidebar_label:"Result",custom_edit_url:null},d=void 0,c={id:"api/interfaces/Presence.Result",title:"Interface: Result",description:"Presence.Result",source:"@site/docs/api/interfaces/Presence.Result.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/Presence.Result",permalink:"/docs/api/interfaces/Presence.Result",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",frontMatter:{id:"Presence.Result",title:"Interface: Result",sidebar_label:"Result",custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"Response",permalink:"/docs/api/interfaces/CommandError.Response"},next:{title:"Welcome!",permalink:"/docs/intro"}},l={},a=[{value:"Properties",id:"properties",level:2},{value:"activities",id:"activities",level:3},{value:"Defined in",id:"defined-in",level:4},{value:"afk",id:"afk",level:3},{value:"Defined in",id:"defined-in-1",level:4},{value:"onRepeat",id:"onrepeat",level:3},{value:"Type declaration",id:"type-declaration",level:4},{value:"Parameters",id:"parameters",level:5},{value:"Returns",id:"returns",level:5},{value:"Defined in",id:"defined-in-2",level:4},{value:"repeat",id:"repeat",level:3},{value:"Defined in",id:"defined-in-3",level:4},{value:"shardId",id:"shardid",level:3},{value:"Defined in",id:"defined-in-4",level:4},{value:"status",id:"status",level:3},{value:"Defined in",id:"defined-in-5",level:4}];function h(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",h5:"h5",hr:"hr",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,i.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.a,{href:"/docs/api/namespaces/Presence",children:"Presence"}),".Result"]}),"\n",(0,r.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,r.jsx)(n.h3,{id:"activities",children:"activities"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"activities"}),": ",(0,r.jsx)(n.code,{children:"ActivitiesOptions"}),"[]"]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/presences.ts#L11",children:"src/core/presences.ts:11"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"afk",children:"afk"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"afk"}),": ",(0,r.jsx)(n.code,{children:"boolean"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/presences.ts#L10",children:"src/core/presences.ts:10"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"onrepeat",children:"onRepeat"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"onRepeat"}),": (",(0,r.jsx)(n.code,{children:"previous"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Presence.Result",children:(0,r.jsx)(n.code,{children:"Result"})}),") => ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Presence.Result",children:(0,r.jsx)(n.code,{children:"Result"})})]}),"\n",(0,r.jsx)(n.h4,{id:"type-declaration",children:"Type declaration"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 (",(0,r.jsx)(n.code,{children:"previous"}),"): ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Presence.Result",children:(0,r.jsx)(n.code,{children:"Result"})})]}),"\n",(0,r.jsx)(n.h5,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"previous"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Presence.Result",children:(0,r.jsx)(n.code,{children:"Result"})})})]})})]}),"\n",(0,r.jsx)(n.h5,{id:"returns",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Presence.Result",children:(0,r.jsx)(n.code,{children:"Result"})})}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/presences.ts#L14",children:"src/core/presences.ts:14"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"repeat",children:"repeat"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"repeat"}),": ",(0,r.jsx)(n.code,{children:"number"})," | [",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Emitter",children:(0,r.jsx)(n.code,{children:"Emitter"})}),", ",(0,r.jsx)(n.code,{children:"string"}),"]"]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/presences.ts#L13",children:"src/core/presences.ts:13"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"shardid",children:"shardId"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"shardId"}),": ",(0,r.jsx)(n.code,{children:"number"}),"[]"]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-4",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/presences.ts#L12",children:"src/core/presences.ts:12"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"status",children:"status"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"status"}),": ",(0,r.jsx)(n.code,{children:"Status"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-5",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/presences.ts#L9",children:"src/core/presences.ts:9"})})]})}function o(e={}){const{wrapper:n}={...(0,i.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(h,{...e})}):h(e)}},8453:(e,n,s)=>{s.d(n,{R:()=>d,x:()=>c});var r=s(6540);const i={},t=r.createContext(i);function d(e){const n=r.useContext(t);return r.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function c(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(i):e.components||i:d(e.components),r.createElement(t.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/888566f1.8c07be1a.js b/assets/js/888566f1.8c07be1a.js deleted file mode 100644 index 2a951b383..000000000 --- a/assets/js/888566f1.8c07be1a.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[5037],{8188:(e,t,n)=>{n.r(t),n.d(t,{assets:()=>d,contentTitle:()=>r,default:()=>h,frontMatter:()=>o,metadata:()=>a,toc:()=>c});var i=n(4848),s=n(8453);const o={},r="Choosing an IDE",a={id:"guide/getting-started/choose-ide",title:"Choosing an IDE",description:"Choosing an IDE is a matter of personal preference. They make programming easier. The following are some",source:"@site/docs/guide/getting-started/choose-ide.md",sourceDirName:"guide/getting-started",slug:"/guide/getting-started/choose-ide",permalink:"/docs/guide/getting-started/choose-ide",draft:!1,unlisted:!1,editUrl:"https://github.com/sern-handler/website/edit/main/docs/guide/getting-started/choose-ide.md",tags:[],version:"current",frontMatter:{},sidebar:"tutorialSidebar",previous:{title:"Introduction",permalink:"/docs/guide/"},next:{title:"Preparing to Code",permalink:"/docs/guide/getting-started/preparing"}},d={},c=[];function l(e){const t={a:"a",h1:"h1",li:"li",p:"p",ul:"ul",...(0,s.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(t.h1,{id:"choosing-an-ide",children:"Choosing an IDE"}),"\n",(0,i.jsx)(t.p,{children:"Choosing an IDE is a matter of personal preference. They make programming easier. The following are some\nsuggestions for choosing an IDE:"}),"\n",(0,i.jsxs)(t.ul,{children:["\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.a,{href:"https://code.visualstudio.com",children:"Visual Studio Code"}),"\n",(0,i.jsxs)(t.ul,{children:["\n",(0,i.jsxs)(t.li,{children:["we have an ",(0,i.jsx)(t.a,{href:"https://marketplace.visualstudio.com/items?itemName=SrIzan.sern-snippets",children:"snippet extension"})," to help automate development :)"]}),"\n"]}),"\n"]}),"\n",(0,i.jsx)(t.li,{children:(0,i.jsx)(t.a,{href:"https://www.sublimetext.com/",children:"Sublime Text"})}),"\n",(0,i.jsx)(t.li,{children:(0,i.jsx)(t.a,{href:"https://notepad-plus-plus.org/",children:"NotePad++"})}),"\n",(0,i.jsxs)(t.li,{children:[(0,i.jsx)(t.a,{href:"https://neovim.io/",children:"nvim"})," (chad)"]}),"\n"]})]})}function h(e={}){const{wrapper:t}={...(0,s.R)(),...e.components};return t?(0,i.jsx)(t,{...e,children:(0,i.jsx)(l,{...e})}):l(e)}},8453:(e,t,n)=>{n.d(t,{R:()=>r,x:()=>a});var i=n(6540);const s={},o=i.createContext(s);function r(e){const t=i.useContext(o);return i.useMemo((function(){return"function"==typeof e?e(t):{...t,...e}}),[t,e])}function a(e){let t;return t=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:r(e.components),i.createElement(o.Provider,{value:t},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/8913.9af1ee1a.js b/assets/js/8913.9af1ee1a.js deleted file mode 100644 index 8dd1d747a..000000000 --- a/assets/js/8913.9af1ee1a.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[8913],{8913:(e,s,b)=>{b.r(s)}}]); \ No newline at end of file diff --git a/assets/js/8a062262.e880708f.js b/assets/js/8a062262.e880708f.js deleted file mode 100644 index 38255a59f..000000000 --- a/assets/js/8a062262.e880708f.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[2684],{5147:(e,n,i)=>{i.r(n),i.d(n,{assets:()=>c,contentTitle:()=>s,default:()=>o,frontMatter:()=>l,metadata:()=>t,toc:()=>h});var r=i(4848),d=i(8453);const l={id:"DiscordEventPlugin",title:"Interface: DiscordEventPlugin ",sidebar_label:"DiscordEventPlugin",sidebar_position:0,custom_edit_url:null},s=void 0,t={id:"api/interfaces/DiscordEventPlugin",title:"Interface: DiscordEventPlugin ",description:"Type parameters",source:"@site/docs/api/interfaces/DiscordEventPlugin.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/DiscordEventPlugin",permalink:"/docs/api/interfaces/DiscordEventPlugin",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"DiscordEventPlugin",title:"Interface: DiscordEventPlugin ",sidebar_label:"DiscordEventPlugin",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"DiscordEventCommand",permalink:"/docs/api/interfaces/DiscordEventCommand"},next:{title:"Disposable",permalink:"/docs/api/interfaces/Disposable"}},c={},h=[{value:"Type parameters",id:"type-parameters",level:2},{value:"Hierarchy",id:"hierarchy",level:2},{value:"Properties",id:"properties",level:2},{value:"description",id:"description",level:3},{value:"Inherited from",id:"inherited-from",level:4},{value:"Defined in",id:"defined-in",level:4},{value:"execute",id:"execute",level:3},{value:"Type declaration",id:"type-declaration",level:4},{value:"Parameters",id:"parameters",level:5},{value:"Returns",id:"returns",level:5},{value:"Defined in",id:"defined-in-1",level:4},{value:"name",id:"name",level:3},{value:"Overrides",id:"overrides",level:4},{value:"Defined in",id:"defined-in-2",level:4},{value:"type",id:"type",level:3},{value:"Overrides",id:"overrides-1",level:4},{value:"Defined in",id:"defined-in-3",level:4}];function a(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",h5:"h5",hr:"hr",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,d.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(n.h2,{id:"type-parameters",children:"Type parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"T"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:["extends keyof ",(0,r.jsx)(n.code,{children:"ClientEvents"})," = keyof ",(0,r.jsx)(n.code,{children:"ClientEvents"})]})]})})]}),"\n",(0,r.jsx)(n.h2,{id:"hierarchy",children:"Hierarchy"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:(0,r.jsx)(n.code,{children:"Plugin"})})}),"\n",(0,r.jsxs)(n.p,{children:["\u21b3 ",(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"DiscordEventPlugin"})})]}),"\n"]}),"\n"]}),"\n",(0,r.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,r.jsx)(n.h3,{id:"description",children:"description"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"description"}),": ",(0,r.jsx)(n.code,{children:"string"})]}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Deprecated"})})}),"\n",(0,r.jsx)(n.p,{children:"will be removed in the next update"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from",children:"Inherited from"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:"Plugin"}),".",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin#description",children:"description"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L33",children:"src/handler/plugins/plugin.ts:33"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"execute",children:"execute"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"execute"}),": (",(0,r.jsx)(n.code,{children:"args"}),": ",(0,r.jsx)(n.code,{children:"ClientEvents"}),"[",(0,r.jsx)(n.code,{children:"T"}),"], ",(0,r.jsx)(n.code,{children:"controller"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Controller",children:(0,r.jsx)(n.code,{children:"Controller"})}),") => ",(0,r.jsx)(n.code,{children:"Awaitable"}),"<",(0,r.jsx)(n.code,{children:"Result"}),"<",(0,r.jsx)(n.code,{children:"void"}),", ",(0,r.jsx)(n.code,{children:"void"}),">>"]}),"\n",(0,r.jsx)(n.h4,{id:"type-declaration",children:"Type declaration"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 (",(0,r.jsx)(n.code,{children:"args"}),", ",(0,r.jsx)(n.code,{children:"controller"}),"): ",(0,r.jsx)(n.code,{children:"Awaitable"}),"<",(0,r.jsx)(n.code,{children:"Result"}),"<",(0,r.jsx)(n.code,{children:"void"}),", ",(0,r.jsx)(n.code,{children:"void"}),">>"]}),"\n",(0,r.jsx)(n.h5,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"args"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"ClientEvents"}),"[",(0,r.jsx)(n.code,{children:"T"}),"]"]})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"controller"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Controller",children:(0,r.jsx)(n.code,{children:"Controller"})})})]})]})]}),"\n",(0,r.jsx)(n.h5,{id:"returns",children:"Returns"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.code,{children:"Awaitable"}),"<",(0,r.jsx)(n.code,{children:"Result"}),"<",(0,r.jsx)(n.code,{children:"void"}),", ",(0,r.jsx)(n.code,{children:"void"}),">>"]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L105",children:"src/handler/plugins/plugin.ts:105"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"name",children:"name"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"name"}),": ",(0,r.jsx)(n.code,{children:"T"})]}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Deprecated"})})}),"\n",(0,r.jsx)(n.p,{children:"will be removed in the next update"}),"\n",(0,r.jsx)(n.h4,{id:"overrides",children:"Overrides"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:"Plugin"}),".",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin#name",children:"name"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L103",children:"src/handler/plugins/plugin.ts:103"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"type",children:"type"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"type"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/enums/PluginType#event",children:(0,r.jsx)(n.code,{children:"Event"})})]}),"\n",(0,r.jsx)(n.h4,{id:"overrides-1",children:"Overrides"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:"Plugin"}),".",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin#type",children:"type"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L104",children:"src/handler/plugins/plugin.ts:104"})})]})}function o(e={}){const{wrapper:n}={...(0,d.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(a,{...e})}):a(e)}},8453:(e,n,i)=>{i.d(n,{R:()=>s,x:()=>t});var r=i(6540);const d={},l=r.createContext(d);function s(e){const n=r.useContext(l);return r.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function t(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(d):e.components||d:s(e.components),r.createElement(l.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/90fdad0c.ebd0c8d8.js b/assets/js/90fdad0c.ebd0c8d8.js deleted file mode 100644 index 9f7ca63c9..000000000 --- a/assets/js/90fdad0c.ebd0c8d8.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[8418],{8868:(e,r,n)=>{n.r(r),n.d(r,{assets:()=>c,contentTitle:()=>t,default:()=>h,frontMatter:()=>l,metadata:()=>d,toc:()=>a});var i=n(4848),s=n(8453);const l={id:"DefaultErrorHandling",title:"Class: DefaultErrorHandling",sidebar_label:"DefaultErrorHandling",sidebar_position:0,custom_edit_url:null},t=void 0,d={id:"api/classes/DefaultErrorHandling",title:"Class: DefaultErrorHandling",description:"Since",source:"@site/docs/api/classes/DefaultErrorHandling.md",sourceDirName:"api/classes",slug:"/api/classes/DefaultErrorHandling",permalink:"/docs/api/classes/DefaultErrorHandling",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"DefaultErrorHandling",title:"Class: DefaultErrorHandling",sidebar_label:"DefaultErrorHandling",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"Context",permalink:"/docs/api/classes/Context"},next:{title:"DefaultLogging",permalink:"/docs/api/classes/DefaultLogging"}},c={},a=[{value:"Implements",id:"implements",level:2},{value:"Constructors",id:"constructors",level:2},{value:"constructor",id:"constructor",level:3},{value:"Returns",id:"returns",level:4},{value:"Properties",id:"properties",level:2},{value:"#keepAlive",id:"keepalive",level:3},{value:"Defined in",id:"defined-in",level:4},{value:"Methods",id:"methods",level:2},{value:"crash",id:"crash",level:3},{value:"Parameters",id:"parameters",level:4},{value:"Returns",id:"returns-1",level:4},{value:"Implementation of",id:"implementation-of",level:4},{value:"Defined in",id:"defined-in-1",level:4},{value:"updateAlive",id:"updatealive",level:3},{value:"Parameters",id:"parameters-1",level:4},{value:"Returns",id:"returns-2",level:4},{value:"Implementation of",id:"implementation-of-1",level:4},{value:"Defined in",id:"defined-in-2",level:4}];function o(e){const r={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",hr:"hr",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,s.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(r.p,{children:(0,i.jsx)(r.strong,{children:(0,i.jsx)(r.code,{children:"Since"})})}),"\n",(0,i.jsx)(r.p,{children:"2.0.0\nVersion 4.0.0 will internalize this api. Please refrain from using the defaults!"}),"\n",(0,i.jsx)(r.h2,{id:"implements",children:"Implements"}),"\n",(0,i.jsxs)(r.ul,{children:["\n",(0,i.jsx)(r.li,{children:(0,i.jsx)(r.a,{href:"/docs/api/interfaces/ErrorHandling",children:(0,i.jsx)(r.code,{children:"ErrorHandling"})})}),"\n"]}),"\n",(0,i.jsx)(r.h2,{id:"constructors",children:"Constructors"}),"\n",(0,i.jsx)(r.h3,{id:"constructor",children:"constructor"}),"\n",(0,i.jsxs)(r.p,{children:["\u2022 ",(0,i.jsx)(r.strong,{children:"new DefaultErrorHandling"}),"(): ",(0,i.jsx)(r.a,{href:"/docs/api/classes/DefaultErrorHandling",children:(0,i.jsx)(r.code,{children:"DefaultErrorHandling"})})]}),"\n",(0,i.jsx)(r.h4,{id:"returns",children:"Returns"}),"\n",(0,i.jsx)(r.p,{children:(0,i.jsx)(r.a,{href:"/docs/api/classes/DefaultErrorHandling",children:(0,i.jsx)(r.code,{children:"DefaultErrorHandling"})})}),"\n",(0,i.jsx)(r.h2,{id:"properties",children:"Properties"}),"\n",(0,i.jsx)(r.h3,{id:"keepalive",children:"#keepAlive"}),"\n",(0,i.jsxs)(r.p,{children:["\u2022 ",(0,i.jsx)(r.code,{children:"Private"})," ",(0,i.jsx)(r.strong,{children:"#keepAlive"}),": ",(0,i.jsx)(r.code,{children:"number"})," = ",(0,i.jsx)(r.code,{children:"1"})]}),"\n",(0,i.jsx)(r.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,i.jsx)(r.p,{children:(0,i.jsx)(r.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/services/error-handling.ts#L13",children:"src/core/structures/services/error-handling.ts:13"})}),"\n",(0,i.jsx)(r.h2,{id:"methods",children:"Methods"}),"\n",(0,i.jsx)(r.h3,{id:"crash",children:"crash"}),"\n",(0,i.jsxs)(r.p,{children:["\u25b8 ",(0,i.jsx)(r.strong,{children:"crash"}),"(",(0,i.jsx)(r.code,{children:"err"}),"): ",(0,i.jsx)(r.code,{children:"never"})]}),"\n",(0,i.jsx)(r.h4,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,i.jsxs)(r.table,{children:[(0,i.jsx)(r.thead,{children:(0,i.jsxs)(r.tr,{children:[(0,i.jsx)(r.th,{style:{textAlign:"left"},children:"Name"}),(0,i.jsx)(r.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,i.jsx)(r.tbody,{children:(0,i.jsxs)(r.tr,{children:[(0,i.jsx)(r.td,{style:{textAlign:"left"},children:(0,i.jsx)(r.code,{children:"err"})}),(0,i.jsx)(r.td,{style:{textAlign:"left"},children:(0,i.jsx)(r.code,{children:"Error"})})]})})]}),"\n",(0,i.jsx)(r.h4,{id:"returns-1",children:"Returns"}),"\n",(0,i.jsx)(r.p,{children:(0,i.jsx)(r.code,{children:"never"})}),"\n",(0,i.jsx)(r.p,{children:(0,i.jsx)(r.strong,{children:(0,i.jsx)(r.code,{children:"Deprecated"})})}),"\n",(0,i.jsx)(r.p,{children:"Version 4 will remove this method"}),"\n",(0,i.jsx)(r.h4,{id:"implementation-of",children:"Implementation of"}),"\n",(0,i.jsxs)(r.p,{children:[(0,i.jsx)(r.a,{href:"/docs/api/interfaces/ErrorHandling",children:"ErrorHandling"}),".",(0,i.jsx)(r.a,{href:"/docs/api/interfaces/ErrorHandling#crash",children:"crash"})]}),"\n",(0,i.jsx)(r.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,i.jsx)(r.p,{children:(0,i.jsx)(r.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/services/error-handling.ts#L9",children:"src/core/structures/services/error-handling.ts:9"})}),"\n",(0,i.jsx)(r.hr,{}),"\n",(0,i.jsx)(r.h3,{id:"updatealive",children:"updateAlive"}),"\n",(0,i.jsxs)(r.p,{children:["\u25b8 ",(0,i.jsx)(r.strong,{children:"updateAlive"}),"(",(0,i.jsx)(r.code,{children:"err"}),"): ",(0,i.jsx)(r.code,{children:"void"})]}),"\n",(0,i.jsx)(r.p,{children:"A function that is called on every throw."}),"\n",(0,i.jsx)(r.h4,{id:"parameters-1",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,i.jsxs)(r.table,{children:[(0,i.jsx)(r.thead,{children:(0,i.jsxs)(r.tr,{children:[(0,i.jsx)(r.th,{style:{textAlign:"left"},children:"Name"}),(0,i.jsx)(r.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,i.jsx)(r.tbody,{children:(0,i.jsxs)(r.tr,{children:[(0,i.jsx)(r.td,{style:{textAlign:"left"},children:(0,i.jsx)(r.code,{children:"err"})}),(0,i.jsx)(r.td,{style:{textAlign:"left"},children:(0,i.jsx)(r.code,{children:"Error"})})]})})]}),"\n",(0,i.jsx)(r.h4,{id:"returns-2",children:"Returns"}),"\n",(0,i.jsx)(r.p,{children:(0,i.jsx)(r.code,{children:"void"})}),"\n",(0,i.jsx)(r.h4,{id:"implementation-of-1",children:"Implementation of"}),"\n",(0,i.jsxs)(r.p,{children:[(0,i.jsx)(r.a,{href:"/docs/api/interfaces/ErrorHandling",children:"ErrorHandling"}),".",(0,i.jsx)(r.a,{href:"/docs/api/interfaces/ErrorHandling#updatealive",children:"updateAlive"})]}),"\n",(0,i.jsx)(r.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,i.jsx)(r.p,{children:(0,i.jsx)(r.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/services/error-handling.ts#L15",children:"src/core/structures/services/error-handling.ts:15"})})]})}function h(e={}){const{wrapper:r}={...(0,s.R)(),...e.components};return r?(0,i.jsx)(r,{...e,children:(0,i.jsx)(o,{...e})}):o(e)}},8453:(e,r,n)=>{n.d(r,{R:()=>t,x:()=>d});var i=n(6540);const s={},l=i.createContext(s);function t(e){const r=i.useContext(l);return i.useMemo((function(){return"function"==typeof e?e(r):{...r,...e}}),[r,e])}function d(e){let r;return r=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:t(e.components),i.createElement(l.Provider,{value:r},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/916aad9f.4db272d1.js b/assets/js/916aad9f.4db272d1.js deleted file mode 100644 index 4b42dadf1..000000000 --- a/assets/js/916aad9f.4db272d1.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[688],{1277:(e,o,t)=>{t.r(o),t.d(o,{assets:()=>l,contentTitle:()=>s,default:()=>c,frontMatter:()=>a,metadata:()=>i,toc:()=>u});var r=t(4848),n=t(8453);const a={slug:"railway-deploy",title:"Deploying sern with Railway",authors:["Duro"],tags:["guides"]},s=void 0,i={permalink:"/blog/railway-deploy",editUrl:"https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/blog/2024-02-23-mdx-blog-post.md",source:"@site/blog/2024-02-23-mdx-blog-post.md",title:"Deploying sern with Railway",description:"In this guide, I'll be showing you how to deploy your sern bot with Railway.",date:"2024-02-23T00:00:00.000Z",formattedDate:"February 23, 2024",tags:[{label:"guides",permalink:"/blog/tags/guides"}],readingTime:1.47,hasTruncateMarker:!1,authors:[{name:"Duro",title:"Developer",url:"https://github.com/DuroCodes",imageURL:"https://github.com/DuroCodes.png",key:"Duro"}],frontMatter:{slug:"railway-deploy",title:"Deploying sern with Railway",authors:["Duro"],tags:["guides"]},unlisted:!1,nextItem:{title:"New logo!",permalink:"/blog/newlogo"}},l={authorsImageUrls:[void 0]},u=[{value:"GitHub Repository",id:"github-repository",level:2},{value:"Railway Setup",id:"railway-setup",level:2},{value:"Deploy",id:"deploy",level:2}];function d(e){const o={a:"a",admonition:"admonition",code:"code",h2:"h2",p:"p",...(0,n.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)(o.p,{children:["In this guide, I'll be showing you how to deploy your sern bot with ",(0,r.jsx)(o.a,{href:"https://railway.app/",children:"Railway"}),"."]}),"\n",(0,r.jsxs)(o.p,{children:["This guide assumes you have a sern bot already set up and ready to deploy. If you don't, you can follow the ",(0,r.jsx)(o.a,{href:"/blog/getting-started",children:"Getting Started"})," guide to set up your bot."]}),"\n",(0,r.jsx)(o.h2,{id:"github-repository",children:"GitHub Repository"}),"\n",(0,r.jsxs)(o.p,{children:["The first thing you'll need to deploy your bot is a GitHub repository for your bot. If you don't have one, you can create one by following the ",(0,r.jsx)(o.a,{href:"https://docs.github.com/en/get-started/quickstart/create-a-repo",children:"GitHub guide"}),"."]}),"\n",(0,r.jsx)(o.p,{children:"Once you have your repository set up, you can push your bot's code to the repository, and you're ready to deploy using Railway."}),"\n",(0,r.jsx)(o.h2,{id:"railway-setup",children:"Railway Setup"}),"\n",(0,r.jsxs)(o.p,{children:["After you have your bot's code in a GitHub repository, you'll need to create an account on Railway. You can sign up using your GitHub account at ",(0,r.jsx)(o.a,{href:"https://railway.app/",children:"railway.app"}),"."]}),"\n",(0,r.jsxs)(o.p,{children:["Once you've created your account, navigate to the ",(0,r.jsx)(o.a,{href:"https://railway.app/dashboard",children:"dashboard"}),' and click the "New Project" button. Click the "Deploy from GitHub repo" button, and select your bot\'s repository.']}),"\n",(0,r.jsxs)(o.p,{children:["Once you've selected your repository, click the \"Add Variables\" button to add your bot's environment variables. You'll need your environment variables from your ",(0,r.jsx)(o.code,{children:".env"})," file to add to Railway. (You can also add these later if you want.)"]}),"\n",(0,r.jsx)(o.h2,{id:"deploy",children:"Deploy"}),"\n",(0,r.jsx)(o.p,{children:"Once you've added your environment variables, click the \"Deploy\" button, and Railway will start deploying your bot. Once the deployment is complete, you'll be able to see your bot's URL and logs."}),"\n",(0,r.jsxs)(o.admonition,{type:"note",children:[(0,r.jsxs)(o.p,{children:["Make sure you add your environment variables, and your node start script is correct in your ",(0,r.jsx)(o.code,{children:"package.json"})," file."]}),(0,r.jsx)(o.p,{children:"If you have any issues deploying your bot, you can check the logs for any errors."})]}),"\n",(0,r.jsxs)(o.p,{children:["That's it! Your bot is now deployed and running on Railway. If you have any issues or questions, feel free to ask in the ",(0,r.jsx)(o.a,{href:"https://sern.dev/discord",children:"sern Discord server"}),"."]})]})}function c(e={}){const{wrapper:o}={...(0,n.R)(),...e.components};return o?(0,r.jsx)(o,{...e,children:(0,r.jsx)(d,{...e})}):d(e)}},8453:(e,o,t)=>{t.d(o,{R:()=>s,x:()=>i});var r=t(6540);const n={},a=r.createContext(n);function s(e){const o=r.useContext(a);return r.useMemo((function(){return"function"==typeof e?e(o):{...o,...e}}),[o,e])}function i(e){let o;return o=e.disableParentContext?"function"==typeof e.components?e.components(n):e.components||n:s(e.components),r.createElement(a.Provider,{value:o},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/9201de17.8c27dbe9.js b/assets/js/9201de17.8c27dbe9.js deleted file mode 100644 index 2ac6e36c1..000000000 --- a/assets/js/9201de17.8c27dbe9.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[5822],{1711:(e,n,i)=>{i.r(n),i.d(n,{assets:()=>d,contentTitle:()=>o,default:()=>u,frontMatter:()=>l,metadata:()=>t,toc:()=>c});var s=i(4848),r=i(8453);const l={},o="Introduction",t={id:"guide/README",title:"Introduction",description:"Welcome to our official guide. This guide will go through all the core features of the framework.",source:"@site/docs/guide/README.md",sourceDirName:"guide",slug:"/guide/",permalink:"/docs/guide/",draft:!1,unlisted:!1,editUrl:"https://github.com/sern-handler/website/edit/main/docs/guide/README.md",tags:[],version:"current",frontMatter:{},sidebar:"tutorialSidebar",previous:{title:"publish",permalink:"/docs/cli/publish"},next:{title:"Choosing an IDE",permalink:"/docs/guide/getting-started/choose-ide"}},d={},c=[{value:"You will learn",id:"you-will-learn",level:2},{value:"Working with plugins",id:"working-with-plugins",level:3},{value:"Events",id:"events",level:3},{value:"Good to know",id:"good-to-know",level:3}];function h(e){const n={a:"a",h1:"h1",h2:"h2",h3:"h3",li:"li",p:"p",ul:"ul",...(0,r.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.h1,{id:"introduction",children:"Introduction"}),"\n",(0,s.jsx)(n.p,{children:"Welcome to our official guide. This guide will go through all the core features of the framework."}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsx)(n.p,{children:"\ud83d\udc96 Thank you for choosing sern to be your framework!"}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsx)(n.p,{children:"Teaching the discord.js library and / or Javascript / Typescript is out of scope of this project, so the documentation assumes you already know these elements."}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"https://discord.js.org/#/",children:"discord.js"})}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"https://nodejs.dev/en/learn/",children:"javascript"})}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"https://www.typescriptlang.org/docs/",children:"typescript"})}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsx)(n.p,{children:"discord.js v14 is the only supported library at the moment"}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(n.h2,{id:"you-will-learn",children:"You will learn"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/docs/guide/walkthrough/goal",children:"sern's goal"})}),"\n",(0,s.jsxs)(n.li,{children:["How to use sern with the ",(0,s.jsx)(n.a,{href:"/docs/guide/walkthrough/cli",children:"CLI"})]}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/docs/guide/walkthrough/first-command",children:"Your first command"})}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/docs/guide/walkthrough/first-command#context-class",children:"The Context class"})}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/docs/guide/walkthrough/autocomplete",children:"Autocomplete"})}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/docs/guide/walkthrough/services",children:"Services"})}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/docs/guide/walkthrough/dependency-injection",children:"dependency injection"})}),"\n"]}),"\n",(0,s.jsx)(n.h3,{id:"working-with-plugins",children:"Working with plugins"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:[(0,s.jsx)(n.a,{href:"/docs/guide/walkthrough/plugins",children:"Plugins"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/docs/guide/walkthrough/plugins#command-plugins",children:"Init Plugins"})}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/docs/guide/walkthrough/plugins#event-plugins",children:"Control Plugins"})}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(n.h3,{id:"events",children:"Events"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/docs/guide/walkthrough/sern-emitter",children:"The SernEmitter class"})}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/docs/guide/walkthrough/first-event",children:"Your first event"})}),"\n"]}),"\n",(0,s.jsx)(n.h3,{id:"good-to-know",children:"Good to know"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.a,{href:"/docs/guide/walkthrough/good-to-know",children:"sern.config.json"})}),"\n"]})]})}function u(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(h,{...e})}):h(e)}},8453:(e,n,i)=>{i.d(n,{R:()=>o,x:()=>t});var s=i(6540);const r={},l=s.createContext(r);function o(e){const n=s.useContext(l);return s.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function t(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(r):e.components||r:o(e.components),s.createElement(l.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/935f2afb.f3ae504a.js b/assets/js/935f2afb.f3ae504a.js deleted file mode 100644 index 688b5d8d2..000000000 --- a/assets/js/935f2afb.f3ae504a.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[8581],{5610:e=>{e.exports=JSON.parse('{"pluginId":"default","version":"current","label":"Next","banner":null,"badge":false,"noIndex":false,"className":"docs-version-current","isLast":true,"docsSidebars":{"tutorialSidebar":[{"type":"category","label":"API","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"Exports","href":"/docs/api/modules","docId":"api/modules","unlisted":false},{"type":"category","label":"Namespaces","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"CommandError","href":"/docs/api/namespaces/CommandError","docId":"api/namespaces/CommandError","unlisted":false},{"type":"link","label":"Presence","href":"/docs/api/namespaces/Presence","docId":"api/namespaces/Presence","unlisted":false},{"type":"link","label":"Sern","href":"/docs/api/namespaces/Sern","docId":"api/namespaces/Sern","unlisted":false}]},{"type":"category","label":"Enumerations","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"CommandType","href":"/docs/api/enums/CommandType","docId":"api/enums/CommandType","unlisted":false},{"type":"link","label":"EventType","href":"/docs/api/enums/EventType","docId":"api/enums/EventType","unlisted":false},{"type":"link","label":"PayloadType","href":"/docs/api/enums/PayloadType","docId":"api/enums/PayloadType","unlisted":false},{"type":"link","label":"PluginType","href":"/docs/api/enums/PluginType","docId":"api/enums/PluginType","unlisted":false},{"type":"link","label":"SernError","href":"/docs/api/enums/SernError","docId":"api/enums/SernError","unlisted":false}]},{"type":"category","label":"Classes","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"CommandExecutable","href":"/docs/api/classes/CommandExecutable","docId":"api/classes/CommandExecutable","unlisted":false},{"type":"link","label":"Context","href":"/docs/api/classes/Context","docId":"api/classes/Context","unlisted":false},{"type":"link","label":"DefaultErrorHandling","href":"/docs/api/classes/DefaultErrorHandling","docId":"api/classes/DefaultErrorHandling","unlisted":false},{"type":"link","label":"DefaultLogging","href":"/docs/api/classes/DefaultLogging","docId":"api/classes/DefaultLogging","unlisted":false},{"type":"link","label":"DefaultModuleManager","href":"/docs/api/classes/DefaultModuleManager","docId":"api/classes/DefaultModuleManager","unlisted":false},{"type":"link","label":"EventExecutable","href":"/docs/api/classes/EventExecutable","docId":"api/classes/EventExecutable","unlisted":false},{"type":"link","label":"ModuleStore","href":"/docs/api/classes/ModuleStore","docId":"api/classes/ModuleStore","unlisted":false},{"type":"link","label":"SernEmitter","href":"/docs/api/classes/SernEmitter","docId":"api/classes/SernEmitter","unlisted":false}]},{"type":"category","label":"Interfaces","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"AutocompleteCommand","href":"/docs/api/interfaces/AutocompleteCommand","docId":"api/interfaces/AutocompleteCommand","unlisted":false},{"type":"link","label":"AutocompletePlugin","href":"/docs/api/interfaces/AutocompletePlugin","docId":"api/interfaces/AutocompletePlugin","unlisted":false},{"type":"link","label":"BothCommand","href":"/docs/api/interfaces/BothCommand","docId":"api/interfaces/BothCommand","unlisted":false},{"type":"link","label":"ButtonCommand","href":"/docs/api/interfaces/ButtonCommand","docId":"api/interfaces/ButtonCommand","unlisted":false},{"type":"link","label":"ChannelSelectCommand","href":"/docs/api/interfaces/ChannelSelectCommand","docId":"api/interfaces/ChannelSelectCommand","unlisted":false},{"type":"link","label":"CommandModuleDefs","href":"/docs/api/interfaces/CommandModuleDefs","docId":"api/interfaces/CommandModuleDefs","unlisted":false},{"type":"link","label":"CommandPlugin","href":"/docs/api/interfaces/CommandPlugin","docId":"api/interfaces/CommandPlugin","unlisted":false},{"type":"link","label":"ContextMenuMsg","href":"/docs/api/interfaces/ContextMenuMsg","docId":"api/interfaces/ContextMenuMsg","unlisted":false},{"type":"link","label":"ContextMenuUser","href":"/docs/api/interfaces/ContextMenuUser","docId":"api/interfaces/ContextMenuUser","unlisted":false},{"type":"link","label":"ControlPlugin","href":"/docs/api/interfaces/ControlPlugin","docId":"api/interfaces/ControlPlugin","unlisted":false},{"type":"link","label":"Controller","href":"/docs/api/interfaces/Controller","docId":"api/interfaces/Controller","unlisted":false},{"type":"link","label":"CoreDependencies","href":"/docs/api/interfaces/CoreDependencies","docId":"api/interfaces/CoreDependencies","unlisted":false},{"type":"link","label":"CoreModuleStore","href":"/docs/api/interfaces/CoreModuleStore","docId":"api/interfaces/CoreModuleStore","unlisted":false},{"type":"link","label":"Dependencies","href":"/docs/api/interfaces/Dependencies","docId":"api/interfaces/Dependencies","unlisted":false},{"type":"link","label":"DependencyConfiguration","href":"/docs/api/interfaces/DependencyConfiguration","docId":"api/interfaces/DependencyConfiguration","unlisted":false},{"type":"link","label":"DiscordEmitterPlugin","href":"/docs/api/interfaces/DiscordEmitterPlugin","docId":"api/interfaces/DiscordEmitterPlugin","unlisted":false},{"type":"link","label":"DiscordEventCommand","href":"/docs/api/interfaces/DiscordEventCommand","docId":"api/interfaces/DiscordEventCommand","unlisted":false},{"type":"link","label":"DiscordEventPlugin","href":"/docs/api/interfaces/DiscordEventPlugin","docId":"api/interfaces/DiscordEventPlugin","unlisted":false},{"type":"link","label":"Disposable","href":"/docs/api/interfaces/Disposable","docId":"api/interfaces/Disposable","unlisted":false},{"type":"link","label":"Emitter","href":"/docs/api/interfaces/Emitter","docId":"api/interfaces/Emitter","unlisted":false},{"type":"link","label":"ErrorHandling","href":"/docs/api/interfaces/ErrorHandling","docId":"api/interfaces/ErrorHandling","unlisted":false},{"type":"link","label":"EventModuleDefs","href":"/docs/api/interfaces/EventModuleDefs","docId":"api/interfaces/EventModuleDefs","unlisted":false},{"type":"link","label":"EventPlugin","href":"/docs/api/interfaces/EventPlugin","docId":"api/interfaces/EventPlugin","unlisted":false},{"type":"link","label":"ExternalEmitterPlugin","href":"/docs/api/interfaces/ExternalEmitterPlugin","docId":"api/interfaces/ExternalEmitterPlugin","unlisted":false},{"type":"link","label":"ExternalEventCommand","href":"/docs/api/interfaces/ExternalEventCommand","docId":"api/interfaces/ExternalEventCommand","unlisted":false},{"type":"link","label":"ExternalEventPlugin","href":"/docs/api/interfaces/ExternalEventPlugin","docId":"api/interfaces/ExternalEventPlugin","unlisted":false},{"type":"link","label":"Init","href":"/docs/api/interfaces/Init","docId":"api/interfaces/Init","unlisted":false},{"type":"link","label":"InitArgs","href":"/docs/api/interfaces/InitArgs","docId":"api/interfaces/InitArgs","unlisted":false},{"type":"link","label":"InitPlugin","href":"/docs/api/interfaces/InitPlugin","docId":"api/interfaces/InitPlugin","unlisted":false},{"type":"link","label":"Logging","href":"/docs/api/interfaces/Logging","docId":"api/interfaces/Logging","unlisted":false},{"type":"link","label":"MentionableSelectCommand","href":"/docs/api/interfaces/MentionableSelectCommand","docId":"api/interfaces/MentionableSelectCommand","unlisted":false},{"type":"link","label":"ModalSubmitCommand","href":"/docs/api/interfaces/ModalSubmitCommand","docId":"api/interfaces/ModalSubmitCommand","unlisted":false},{"type":"link","label":"Module","href":"/docs/api/interfaces/Module","docId":"api/interfaces/Module","unlisted":false},{"type":"link","label":"ModuleManager","href":"/docs/api/interfaces/ModuleManager","docId":"api/interfaces/ModuleManager","unlisted":false},{"type":"link","label":"Plugin","href":"/docs/api/interfaces/Plugin","docId":"api/interfaces/Plugin","unlisted":false},{"type":"link","label":"RoleSelectCommand","href":"/docs/api/interfaces/RoleSelectCommand","docId":"api/interfaces/RoleSelectCommand","unlisted":false},{"type":"link","label":"SernAutocompleteData","href":"/docs/api/interfaces/SernAutocompleteData","docId":"api/interfaces/SernAutocompleteData","unlisted":false},{"type":"link","label":"SernEmitterPlugin","href":"/docs/api/interfaces/SernEmitterPlugin","docId":"api/interfaces/SernEmitterPlugin","unlisted":false},{"type":"link","label":"SernEventCommand","href":"/docs/api/interfaces/SernEventCommand","docId":"api/interfaces/SernEventCommand","unlisted":false},{"type":"link","label":"SernEventPlugin","href":"/docs/api/interfaces/SernEventPlugin","docId":"api/interfaces/SernEventPlugin","unlisted":false},{"type":"link","label":"SernEventsMapping","href":"/docs/api/interfaces/SernEventsMapping","docId":"api/interfaces/SernEventsMapping","unlisted":false},{"type":"link","label":"SernSubCommandData","href":"/docs/api/interfaces/SernSubCommandData","docId":"api/interfaces/SernSubCommandData","unlisted":false},{"type":"link","label":"SernSubCommandGroupData","href":"/docs/api/interfaces/SernSubCommandGroupData","docId":"api/interfaces/SernSubCommandGroupData","unlisted":false},{"type":"link","label":"SlashCommand","href":"/docs/api/interfaces/SlashCommand","docId":"api/interfaces/SlashCommand","unlisted":false},{"type":"link","label":"StringSelectCommand","href":"/docs/api/interfaces/StringSelectCommand","docId":"api/interfaces/StringSelectCommand","unlisted":false},{"type":"link","label":"TextCommand","href":"/docs/api/interfaces/TextCommand","docId":"api/interfaces/TextCommand","unlisted":false},{"type":"link","label":"UserSelectCommand","href":"/docs/api/interfaces/UserSelectCommand","docId":"api/interfaces/UserSelectCommand","unlisted":false},{"type":"link","label":"Wrapper","href":"/docs/api/interfaces/Wrapper","docId":"api/interfaces/Wrapper","unlisted":false},{"type":"link","label":"Response","href":"/docs/api/interfaces/CommandError.Response","docId":"api/interfaces/CommandError.Response","unlisted":false},{"type":"link","label":"Result","href":"/docs/api/interfaces/Presence.Result","docId":"api/interfaces/Presence.Result","unlisted":false}]}],"href":"/docs/api/"},{"type":"link","label":"Welcome!","href":"/docs/intro","docId":"intro","unlisted":false},{"type":"category","label":"CLI","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"build","href":"/docs/cli/build","docId":"cli/build","unlisted":false},{"type":"link","label":"clear","href":"/docs/cli/clear","docId":"cli/clear","unlisted":false},{"type":"link","label":"extra","href":"/docs/cli/extra","docId":"cli/extra","unlisted":false},{"type":"link","label":"publish","href":"/docs/cli/publish","docId":"cli/publish","unlisted":false}],"href":"/docs/cli/"},{"type":"category","label":"Introduction","collapsible":true,"collapsed":true,"items":[{"type":"category","label":"Getting Started","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"Choosing an IDE","href":"/docs/guide/getting-started/choose-ide","docId":"guide/getting-started/choose-ide","unlisted":false},{"type":"link","label":"Preparing to Code","href":"/docs/guide/getting-started/preparing","docId":"guide/getting-started/preparing","unlisted":false}]},{"type":"category","label":"Walkthrough","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"Goal","href":"/docs/guide/walkthrough/goal","docId":"guide/walkthrough/goal","unlisted":false},{"type":"link","label":"Create a new project","href":"/docs/guide/walkthrough/new-project","docId":"guide/walkthrough/new-project","unlisted":false},{"type":"link","label":"CLI","href":"/docs/guide/walkthrough/cli","docId":"guide/walkthrough/cli","unlisted":false},{"type":"link","label":"Transition from v2 to v3","href":"/docs/guide/walkthrough/transition","docId":"guide/walkthrough/transition","unlisted":false},{"type":"link","label":"First Command","href":"/docs/guide/walkthrough/first-command","docId":"guide/walkthrough/first-command","unlisted":false},{"type":"link","label":"First Event Module","href":"/docs/guide/walkthrough/first-event","docId":"guide/walkthrough/first-event","unlisted":false},{"type":"link","label":"Plugins","href":"/docs/guide/walkthrough/plugins","docId":"guide/walkthrough/plugins","unlisted":false},{"type":"link","label":"Services","href":"/docs/guide/walkthrough/services","docId":"guide/walkthrough/services","unlisted":false},{"type":"link","label":"Autocomplete","href":"/docs/guide/walkthrough/autocomplete","docId":"guide/walkthrough/autocomplete","unlisted":false},{"type":"link","label":"Dependency Injection","href":"/docs/guide/walkthrough/dependency-injection","docId":"guide/walkthrough/dependency-injection","unlisted":false},{"type":"link","label":"The SernEmitter class","href":"/docs/guide/walkthrough/sern-emitter","docId":"guide/walkthrough/sern-emitter","unlisted":false},{"type":"link","label":"Conclusion","href":"/docs/guide/walkthrough/conclusion","docId":"guide/walkthrough/conclusion","unlisted":false},{"type":"link","label":"Good to know","href":"/docs/guide/walkthrough/good-to-know","docId":"guide/walkthrough/good-to-know","unlisted":false}]}],"href":"/docs/guide/"}]},"docs":{"api/classes/CommandExecutable":{"id":"api/classes/CommandExecutable","title":"Class: CommandExecutable ","description":"Deprecated","sidebar":"tutorialSidebar"},"api/classes/Context":{"id":"api/classes/Context","title":"Class: Context","description":"Since","sidebar":"tutorialSidebar"},"api/classes/DefaultErrorHandling":{"id":"api/classes/DefaultErrorHandling","title":"Class: DefaultErrorHandling","description":"Since","sidebar":"tutorialSidebar"},"api/classes/DefaultLogging":{"id":"api/classes/DefaultLogging","title":"Class: DefaultLogging","description":"Since","sidebar":"tutorialSidebar"},"api/classes/DefaultModuleManager":{"id":"api/classes/DefaultModuleManager","title":"Class: DefaultModuleManager","description":"Since","sidebar":"tutorialSidebar"},"api/classes/EventExecutable":{"id":"api/classes/EventExecutable","title":"Class: EventExecutable ","description":"Deprecated","sidebar":"tutorialSidebar"},"api/classes/ModuleStore":{"id":"api/classes/ModuleStore","title":"Class: ModuleStore","description":"Constructors","sidebar":"tutorialSidebar"},"api/classes/SernEmitter":{"id":"api/classes/SernEmitter","title":"Class: SernEmitter","description":"Since","sidebar":"tutorialSidebar"},"api/enums/CommandType":{"id":"api/enums/CommandType","title":"Enumeration: CommandType","description":"Since","sidebar":"tutorialSidebar"},"api/enums/EventType":{"id":"api/enums/EventType","title":"Enumeration: EventType","description":"A bitfield that discriminates event modules","sidebar":"tutorialSidebar"},"api/enums/PayloadType":{"id":"api/enums/PayloadType","title":"Enumeration: PayloadType","description":"Enumeration Members","sidebar":"tutorialSidebar"},"api/enums/PluginType":{"id":"api/enums/PluginType","title":"Enumeration: PluginType","description":"A bitfield that discriminates plugins","sidebar":"tutorialSidebar"},"api/enums/SernError":{"id":"api/enums/SernError","title":"Enumeration: SernError","description":"Enumeration Members","sidebar":"tutorialSidebar"},"api/index":{"id":"api/index","title":"@sern/handler","description":"Handlers. Redefined.","sidebar":"tutorialSidebar"},"api/interfaces/AutocompleteCommand":{"id":"api/interfaces/AutocompleteCommand","title":"Interface: AutocompleteCommand","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/AutocompletePlugin":{"id":"api/interfaces/AutocompletePlugin","title":"Interface: AutocompletePlugin","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/BothCommand":{"id":"api/interfaces/BothCommand","title":"Interface: BothCommand","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/ButtonCommand":{"id":"api/interfaces/ButtonCommand","title":"Interface: ButtonCommand","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/ChannelSelectCommand":{"id":"api/interfaces/ChannelSelectCommand","title":"Interface: ChannelSelectCommand","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/CommandError.Response":{"id":"api/interfaces/CommandError.Response","title":"Interface: Response","description":"CommandError.Response","sidebar":"tutorialSidebar"},"api/interfaces/CommandModuleDefs":{"id":"api/interfaces/CommandModuleDefs","title":"Interface: CommandModuleDefs","description":"Properties","sidebar":"tutorialSidebar"},"api/interfaces/CommandPlugin":{"id":"api/interfaces/CommandPlugin","title":"Interface: CommandPlugin ","description":"Deprecated","sidebar":"tutorialSidebar"},"api/interfaces/ContextMenuMsg":{"id":"api/interfaces/ContextMenuMsg","title":"Interface: ContextMenuMsg","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/ContextMenuUser":{"id":"api/interfaces/ContextMenuUser","title":"Interface: ContextMenuUser","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/Controller":{"id":"api/interfaces/Controller","title":"Interface: Controller","description":"Properties","sidebar":"tutorialSidebar"},"api/interfaces/ControlPlugin":{"id":"api/interfaces/ControlPlugin","title":"Interface: ControlPlugin ","description":"Type parameters","sidebar":"tutorialSidebar"},"api/interfaces/CoreDependencies":{"id":"api/interfaces/CoreDependencies","title":"Interface: CoreDependencies","description":"Properties","sidebar":"tutorialSidebar"},"api/interfaces/CoreModuleStore":{"id":"api/interfaces/CoreModuleStore","title":"Interface: CoreModuleStore","description":"Represents a core module store that stores IDs mapped to file paths.","sidebar":"tutorialSidebar"},"api/interfaces/Dependencies":{"id":"api/interfaces/Dependencies","title":"Interface: Dependencies","description":"Properties","sidebar":"tutorialSidebar"},"api/interfaces/DependencyConfiguration":{"id":"api/interfaces/DependencyConfiguration","title":"Interface: DependencyConfiguration ","description":"Type parameters","sidebar":"tutorialSidebar"},"api/interfaces/DiscordEmitterPlugin":{"id":"api/interfaces/DiscordEmitterPlugin","title":"Interface: DiscordEmitterPlugin","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/DiscordEventCommand":{"id":"api/interfaces/DiscordEventCommand","title":"Interface: DiscordEventCommand ","description":"Type parameters","sidebar":"tutorialSidebar"},"api/interfaces/DiscordEventPlugin":{"id":"api/interfaces/DiscordEventPlugin","title":"Interface: DiscordEventPlugin ","description":"Type parameters","sidebar":"tutorialSidebar"},"api/interfaces/Disposable":{"id":"api/interfaces/Disposable","title":"Interface: Disposable","description":"Represents a Disposable contract.","sidebar":"tutorialSidebar"},"api/interfaces/Emitter":{"id":"api/interfaces/Emitter","title":"Interface: Emitter","description":"Methods","sidebar":"tutorialSidebar"},"api/interfaces/ErrorHandling":{"id":"api/interfaces/ErrorHandling","title":"Interface: ErrorHandling","description":"Since","sidebar":"tutorialSidebar"},"api/interfaces/EventModuleDefs":{"id":"api/interfaces/EventModuleDefs","title":"Interface: EventModuleDefs","description":"Properties","sidebar":"tutorialSidebar"},"api/interfaces/EventPlugin":{"id":"api/interfaces/EventPlugin","title":"Interface: EventPlugin ","description":"Deprecated","sidebar":"tutorialSidebar"},"api/interfaces/ExternalEmitterPlugin":{"id":"api/interfaces/ExternalEmitterPlugin","title":"Interface: ExternalEmitterPlugin","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/ExternalEventCommand":{"id":"api/interfaces/ExternalEventCommand","title":"Interface: ExternalEventCommand","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/ExternalEventPlugin":{"id":"api/interfaces/ExternalEventPlugin","title":"Interface: ExternalEventPlugin","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/Init":{"id":"api/interfaces/Init","title":"Interface: Init","description":"Represents an initialization contract.","sidebar":"tutorialSidebar"},"api/interfaces/InitArgs":{"id":"api/interfaces/InitArgs","title":"Interface: InitArgs ","description":"Type parameters","sidebar":"tutorialSidebar"},"api/interfaces/InitPlugin":{"id":"api/interfaces/InitPlugin","title":"Interface: InitPlugin ","description":"Type parameters","sidebar":"tutorialSidebar"},"api/interfaces/Logging":{"id":"api/interfaces/Logging","title":"Interface: Logging ","description":"Since","sidebar":"tutorialSidebar"},"api/interfaces/MentionableSelectCommand":{"id":"api/interfaces/MentionableSelectCommand","title":"Interface: MentionableSelectCommand","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/ModalSubmitCommand":{"id":"api/interfaces/ModalSubmitCommand","title":"Interface: ModalSubmitCommand","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/Module":{"id":"api/interfaces/Module","title":"Interface: Module","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/ModuleManager":{"id":"api/interfaces/ModuleManager","title":"Interface: ModuleManager","description":"Since","sidebar":"tutorialSidebar"},"api/interfaces/Plugin":{"id":"api/interfaces/Plugin","title":"Interface: Plugin ","description":"Type parameters","sidebar":"tutorialSidebar"},"api/interfaces/Presence.Result":{"id":"api/interfaces/Presence.Result","title":"Interface: Result","description":"Presence.Result","sidebar":"tutorialSidebar"},"api/interfaces/RoleSelectCommand":{"id":"api/interfaces/RoleSelectCommand","title":"Interface: RoleSelectCommand","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/SernAutocompleteData":{"id":"api/interfaces/SernAutocompleteData","title":"Interface: SernAutocompleteData","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/SernEmitterPlugin":{"id":"api/interfaces/SernEmitterPlugin","title":"Interface: SernEmitterPlugin","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/SernEventCommand":{"id":"api/interfaces/SernEventCommand","title":"Interface: SernEventCommand ","description":"Type parameters","sidebar":"tutorialSidebar"},"api/interfaces/SernEventPlugin":{"id":"api/interfaces/SernEventPlugin","title":"Interface: SernEventPlugin ","description":"Type parameters","sidebar":"tutorialSidebar"},"api/interfaces/SernEventsMapping":{"id":"api/interfaces/SernEventsMapping","title":"Interface: SernEventsMapping","description":"Properties","sidebar":"tutorialSidebar"},"api/interfaces/SernSubCommandData":{"id":"api/interfaces/SernSubCommandData","title":"Interface: SernSubCommandData","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/SernSubCommandGroupData":{"id":"api/interfaces/SernSubCommandGroupData","title":"Interface: SernSubCommandGroupData","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/SlashCommand":{"id":"api/interfaces/SlashCommand","title":"Interface: SlashCommand","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/StringSelectCommand":{"id":"api/interfaces/StringSelectCommand","title":"Interface: StringSelectCommand","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/TextCommand":{"id":"api/interfaces/TextCommand","title":"Interface: TextCommand","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/UserSelectCommand":{"id":"api/interfaces/UserSelectCommand","title":"Interface: UserSelectCommand","description":"Hierarchy","sidebar":"tutorialSidebar"},"api/interfaces/Wrapper":{"id":"api/interfaces/Wrapper","title":"Interface: Wrapper","description":"Properties","sidebar":"tutorialSidebar"},"api/modules":{"id":"api/modules","title":"@sern/handler","description":"Namespaces","sidebar":"tutorialSidebar"},"api/namespaces/CommandError":{"id":"api/namespaces/CommandError","title":"Namespace: CommandError","description":"Interfaces","sidebar":"tutorialSidebar"},"api/namespaces/Presence":{"id":"api/namespaces/Presence","title":"Namespace: Presence","description":"Interfaces","sidebar":"tutorialSidebar"},"api/namespaces/Sern":{"id":"api/namespaces/Sern","title":"Namespace: Sern","description":"Functions","sidebar":"tutorialSidebar"},"cli/build":{"id":"cli/build","title":"build","description":"Guiding Principles","sidebar":"tutorialSidebar"},"cli/clear":{"id":"cli/clear","title":"clear","description":"Implicits","sidebar":"tutorialSidebar"},"cli/extra":{"id":"cli/extra","title":"extra","description":"This command is pretty straightfoward. Install utilities into your application. Assumes you have a sern.config.json.","sidebar":"tutorialSidebar"},"cli/publish":{"id":"cli/publish","title":"publish","description":"Implicits","sidebar":"tutorialSidebar"},"cli/README":{"id":"cli/README","title":"CLI","description":"Publish commands to the API, install plugins, and use other tools provided by our cli.","sidebar":"tutorialSidebar"},"guide/getting-started/choose-ide":{"id":"guide/getting-started/choose-ide","title":"Choosing an IDE","description":"Choosing an IDE is a matter of personal preference. They make programming easier. The following are some","sidebar":"tutorialSidebar"},"guide/getting-started/preparing":{"id":"guide/getting-started/preparing","title":"Preparing to Code","description":"After installing an IDE, you need to install node.","sidebar":"tutorialSidebar"},"guide/README":{"id":"guide/README","title":"Introduction","description":"Welcome to our official guide. This guide will go through all the core features of the framework.","sidebar":"tutorialSidebar"},"guide/walkthrough/autocomplete":{"id":"guide/walkthrough/autocomplete","title":"Autocomplete","description":"Autocomplete is a special interaction where it can happen on multiple options on a single command. We\'ve handled this with a simple","sidebar":"tutorialSidebar"},"guide/walkthrough/cli":{"id":"guide/walkthrough/cli","title":"CLI","description":"Setting up the CLI is easy.","sidebar":"tutorialSidebar"},"guide/walkthrough/conclusion":{"id":"guide/walkthrough/conclusion","title":"Conclusion","description":"If you reached this far, thank you for reading! We hope you have learned the necessities you need","sidebar":"tutorialSidebar"},"guide/walkthrough/dependency-injection":{"id":"guide/walkthrough/dependency-injection","title":"Dependency Injection","description":"This contains version 2 code. Please view transitioning to v3","sidebar":"tutorialSidebar"},"guide/walkthrough/first-command":{"id":"guide/walkthrough/first-command","title":"First Command","description":"We will dissect a basic command.","sidebar":"tutorialSidebar"},"guide/walkthrough/first-event":{"id":"guide/walkthrough/first-event","title":"First Event Module","description":"We will dissect a basic event module.","sidebar":"tutorialSidebar"},"guide/walkthrough/goal":{"id":"guide/walkthrough/goal","title":"Goal","description":"This walkthrough will be written in TypeScript but will have JavaScript snippets throughout.","sidebar":"tutorialSidebar"},"guide/walkthrough/good-to-know":{"id":"guide/walkthrough/good-to-know","title":"Good to know","description":"sern.config.json","sidebar":"tutorialSidebar"},"guide/walkthrough/new-project":{"id":"guide/walkthrough/new-project","title":"Create a new project","description":"and follow the interactive prompts.","sidebar":"tutorialSidebar"},"guide/walkthrough/plugins":{"id":"guide/walkthrough/plugins","title":"Plugins","description":"TLDR: Plugins help reduce code repetition and are installable via sern plugins. Put them onto the plugins field of a command/event module.","sidebar":"tutorialSidebar"},"guide/walkthrough/sern-emitter":{"id":"guide/walkthrough/sern-emitter","title":"The SernEmitter class","description":"You\'re shipped with the SernEmitter. This EventEmitter listens to","sidebar":"tutorialSidebar"},"guide/walkthrough/services":{"id":"guide/walkthrough/services","title":"Services","description":"This is version 3 api only!!","sidebar":"tutorialSidebar"},"guide/walkthrough/transition":{"id":"guide/walkthrough/transition","title":"Transition from v2 to v3","description":"v3 comes with the new Service api. To make sure to enable intellisense","sidebar":"tutorialSidebar"},"intro":{"id":"intro","title":"Welcome!","description":"Please read the transition page if you are moving from version 2 to version 3.","sidebar":"tutorialSidebar"}}}')}}]); \ No newline at end of file diff --git a/assets/js/9462.23a81660.js b/assets/js/9462.23a81660.js deleted file mode 100644 index 77125fb18..000000000 --- a/assets/js/9462.23a81660.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[9462],{9462:(e,t,r)=>{function n(e,t){var r=void 0;return function(){for(var n=arguments.length,o=new Array(n),i=0;i vn});var a=function(){};function c(e){var t=e.item,r=e.items;return{index:t.__autocomplete_indexName,items:[t],positions:[1+r.findIndex((function(e){return e.objectID===t.objectID}))],queryID:t.__autocomplete_queryID,algoliaSource:["autocomplete"]}}function l(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=r){var n,o,i,a,c=[],l=!0,u=!1;try{if(i=(r=r.call(e)).next,0===t){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=i.call(r)).done)&&(c.push(n.value),c.length!==t);l=!0);}catch(s){u=!0,o=s}finally{try{if(!l&&null!=r.return&&(a=r.return(),Object(a)!==a))return}finally{if(u)throw o}}return c}}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return u(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);"Object"===r&&e.constructor&&(r=e.constructor.name);if("Map"===r||"Set"===r)return Array.from(e);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return u(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r e.length)&&(t=e.length);for(var r=0,n=new Array(t);r =0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n =0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}function y(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function h(e){for(var t=1;t =3||2===r&&n>=4||1===r&&n>=10);function i(t,r,n){if(o&&void 0!==n){var i=n[0].__autocomplete_algoliaCredentials,a={"X-Algolia-Application-Id":i.appId,"X-Algolia-API-Key":i.apiKey};e.apply(void 0,[t].concat(p(r),[{headers:a}]))}else e.apply(void 0,[t].concat(p(r)))}return{init:function(t,r){e("init",{appId:t,apiKey:r})},setUserToken:function(t){e("setUserToken",t)},clickedObjectIDsAfterSearch:function(){for(var e=arguments.length,t=new Array(e),r=0;r 0&&i("clickedObjectIDsAfterSearch",g(t),t[0].items)},clickedObjectIDs:function(){for(var e=arguments.length,t=new Array(e),r=0;r 0&&i("clickedObjectIDs",g(t),t[0].items)},clickedFilters:function(){for(var t=arguments.length,r=new Array(t),n=0;n 0&&e.apply(void 0,["clickedFilters"].concat(r))},convertedObjectIDsAfterSearch:function(){for(var e=arguments.length,t=new Array(e),r=0;r 0&&i("convertedObjectIDsAfterSearch",g(t),t[0].items)},convertedObjectIDs:function(){for(var e=arguments.length,t=new Array(e),r=0;r 0&&i("convertedObjectIDs",g(t),t[0].items)},convertedFilters:function(){for(var t=arguments.length,r=new Array(t),n=0;n 0&&e.apply(void 0,["convertedFilters"].concat(r))},viewedObjectIDs:function(){for(var e=arguments.length,t=new Array(e),r=0;r 0&&t.reduce((function(e,t){var r=t.items,n=d(t,f);return[].concat(p(e),p(function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:20,r=[],n=0;n 0&&e.apply(void 0,["viewedFilters"].concat(r))}}}function S(e){var t=e.items.reduce((function(e,t){var r;return e[t.__autocomplete_indexName]=(null!==(r=e[t.__autocomplete_indexName])&&void 0!==r?r:[]).concat(t),e}),{});return Object.keys(t).map((function(e){return{index:e,items:t[e],algoliaSource:["autocomplete"]}}))}function j(e){return e.objectID&&e.__autocomplete_indexName&&e.__autocomplete_queryID}function w(e){return w="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},w(e)}function E(e){return function(e){if(Array.isArray(e))return P(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(!e)return;if("string"==typeof e)return P(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);"Object"===r&&e.constructor&&(r=e.constructor.name);if("Map"===r||"Set"===r)return Array.from(e);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return P(e,t)}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function P(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r 0&&C({onItemsChange:o,items:r,insights:f,state:t}))}}),0);return{name:"aa.algoliaInsightsPlugin",subscribe:function(e){var t=e.setContext,r=e.onSelect,n=e.onActive;s("addAlgoliaAgent","insights-plugin"),t({algoliaInsightsPlugin:{__algoliaSearchParameters:{clickAnalytics:!0},insights:f}}),r((function(e){var t=e.item,r=e.state,n=e.event;j(t)&&l({state:r,event:n,insights:f,item:t,insightsEvents:[D({eventName:"Item Selected"},c({item:t,items:m.current}))]})})),n((function(e){var t=e.item,r=e.state,n=e.event;j(t)&&u({state:r,event:n,insights:f,item:t,insightsEvents:[D({eventName:"Item Active"},c({item:t,items:m.current}))]})}))},onStateChange:function(e){var t=e.state;p({state:t})},__autocomplete_pluginOptions:e}}function N(e){return N="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},N(e)}function T(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function q(e,t,r){return(t=function(e){var t=function(e,t){if("object"!==N(e)||null===e)return e;var r=e[Symbol.toPrimitive];if(void 0!==r){var n=r.call(e,t||"default");if("object"!==N(n))return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===t?String:Number)(e)}(e,"string");return"symbol"===N(t)?t:String(t)}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function R(e,t,r){var n,o=t.initialState;return{getState:function(){return o},dispatch:function(n,i){var a=function(e){for(var t=1;t e.length)&&(t=e.length);for(var r=0,n=new Array(t);r 0},reshape:function(e){return e.sources}},e),{},{id:null!==(r=e.id)&&void 0!==r?r:"autocomplete-".concat(V++),plugins:o,initialState:X({activeItemId:null,query:"",completion:null,collections:[],isOpen:!1,status:"idle",context:{}},e.initialState),onStateChange:function(t){var r;null===(r=e.onStateChange)||void 0===r||r.call(e,t),o.forEach((function(e){var r;return null===(r=e.onStateChange)||void 0===r?void 0:r.call(e,t)}))},onSubmit:function(t){var r;null===(r=e.onSubmit)||void 0===r||r.call(e,t),o.forEach((function(e){var r;return null===(r=e.onSubmit)||void 0===r?void 0:r.call(e,t)}))},onReset:function(t){var r;null===(r=e.onReset)||void 0===r||r.call(e,t),o.forEach((function(e){var r;return null===(r=e.onReset)||void 0===r?void 0:r.call(e,t)}))},getSources:function(r){return Promise.all([].concat(Q(o.map((function(e){return e.getSources}))),[e.getSources]).filter(Boolean).map((function(e){return function(e,t){var r=[];return Promise.resolve(e(t)).then((function(e){return Array.isArray(e),Promise.all(e.filter((function(e){return Boolean(e)})).map((function(e){if(e.sourceId,r.includes(e.sourceId))throw new Error("[Autocomplete] The `sourceId` ".concat(JSON.stringify(e.sourceId)," is not unique."));r.push(e.sourceId);var t={getItemInputValue:function(e){return e.state.query},getItemUrl:function(){},onSelect:function(e){(0,e.setIsOpen)(!1)},onActive:a,onResolve:a};Object.keys(t).forEach((function(e){t[e].__default=!0}));var n=$($({},t),e);return Promise.resolve(n)})))}))}(e,r)}))).then((function(e){return L(e)})).then((function(e){return e.map((function(e){return X(X({},e),{},{onSelect:function(r){e.onSelect(r),t.forEach((function(e){var t;return null===(t=e.onSelect)||void 0===t?void 0:t.call(e,r)}))},onActive:function(r){e.onActive(r),t.forEach((function(e){var t;return null===(t=e.onActive)||void 0===t?void 0:t.call(e,r)}))},onResolve:function(r){e.onResolve(r),t.forEach((function(e){var t;return null===(t=e.onResolve)||void 0===t?void 0:t.call(e,r)}))}})}))}))},navigator:X({navigate:function(e){var t=e.itemUrl;n.location.assign(t)},navigateNewTab:function(e){var t=e.itemUrl,r=n.open(t,"_blank","noopener");null==r||r.focus()},navigateNewWindow:function(e){var t=e.itemUrl;n.open(t,"_blank","noopener")}},e.navigator)})}function te(e){return te="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},te(e)}function re(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function ne(e){for(var t=1;t e.length)&&(t=e.length);for(var r=0,n=new Array(t);r =0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n =0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}var Ie,De,Ae,ke=null,xe=(Ie=-1,De=-1,Ae=void 0,function(e){var t=++Ie;return Promise.resolve(e).then((function(e){return Ae&&t =0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n =0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}var Me=/((gt|sm)-|galaxy nexus)|samsung[- ]|samsungbrowser/i;function He(e){return He="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},He(e)}var Fe=["props","refresh","store"],Ue=["inputElement","formElement","panelElement"],Be=["inputElement"],Ve=["inputElement","maxLength"],Ke=["sourceIndex"],$e=["sourceIndex"],Je=["item","source","sourceIndex"];function ze(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function We(e){for(var t=1;t =0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n =0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}function Ge(e){var t=e.props,r=e.refresh,n=e.store,o=Ze(e,Fe),i=function(e,t){return void 0!==t?"".concat(e,"-").concat(t):e};return{getEnvironmentProps:function(e){var r=e.inputElement,o=e.formElement,i=e.panelElement;function a(e){!n.getState().isOpen&&n.pendingRequests.isEmpty()||e.target===r||!1===[o,i].some((function(t){return r=t,n=e.target,r===n||r.contains(n);var r,n}))&&(n.dispatch("blur",null),t.debug||n.pendingRequests.cancelAll())}return We({onTouchStart:a,onMouseDown:a,onTouchMove:function(e){!1!==n.getState().isOpen&&r===t.environment.document.activeElement&&e.target!==r&&r.blur()}},Ze(e,Ue))},getRootProps:function(e){return We({role:"combobox","aria-expanded":n.getState().isOpen,"aria-haspopup":"listbox","aria-owns":n.getState().isOpen?"".concat(t.id,"-list"):void 0,"aria-labelledby":"".concat(t.id,"-label")},e)},getFormProps:function(e){e.inputElement;return We({action:"",noValidate:!0,role:"search",onSubmit:function(i){var a;i.preventDefault(),t.onSubmit(We({event:i,refresh:r,state:n.getState()},o)),n.dispatch("submit",null),null===(a=e.inputElement)||void 0===a||a.blur()},onReset:function(i){var a;i.preventDefault(),t.onReset(We({event:i,refresh:r,state:n.getState()},o)),n.dispatch("reset",null),null===(a=e.inputElement)||void 0===a||a.focus()}},Ze(e,Be))},getLabelProps:function(e){var r=e||{},n=r.sourceIndex,o=Ze(r,Ke);return We({htmlFor:"".concat(i(t.id,n),"-input"),id:"".concat(i(t.id,n),"-label")},o)},getInputProps:function(e){var i;function c(e){(t.openOnFocus||Boolean(n.getState().query))&&Ce(We({event:e,props:t,query:n.getState().completion||n.getState().query,refresh:r,store:n},o)),n.dispatch("focus",null)}var l=e||{},u=(l.inputElement,l.maxLength),s=void 0===u?512:u,f=Ze(l,Ve),m=ge(n.getState()),p=function(e){return Boolean(e&&e.match(Me))}((null===(i=t.environment.navigator)||void 0===i?void 0:i.userAgent)||""),v=null!=m&&m.itemUrl&&!p?"go":"search";return We({"aria-autocomplete":"both","aria-activedescendant":n.getState().isOpen&&null!==n.getState().activeItemId?"".concat(t.id,"-item-").concat(n.getState().activeItemId):void 0,"aria-controls":n.getState().isOpen?"".concat(t.id,"-list"):void 0,"aria-labelledby":"".concat(t.id,"-label"),value:n.getState().completion||n.getState().query,id:"".concat(t.id,"-input"),autoComplete:"off",autoCorrect:"off",autoCapitalize:"off",enterKeyHint:v,spellCheck:"false",autoFocus:t.autoFocus,placeholder:t.placeholder,maxLength:s,type:"search",onChange:function(e){Ce(We({event:e,props:t,query:e.currentTarget.value.slice(0,s),refresh:r,store:n},o))},onKeyDown:function(e){!function(e){var t=e.event,r=e.props,n=e.refresh,o=e.store,i=Le(e,Ne);if("ArrowUp"===t.key||"ArrowDown"===t.key){var a=function(){var e=r.environment.document.getElementById("".concat(r.id,"-item-").concat(o.getState().activeItemId));e&&(e.scrollIntoViewIfNeeded?e.scrollIntoViewIfNeeded(!1):e.scrollIntoView(!1))},c=function(){var e=ge(o.getState());if(null!==o.getState().activeItemId&&e){var r=e.item,a=e.itemInputValue,c=e.itemUrl,l=e.source;l.onActive(qe({event:t,item:r,itemInputValue:a,itemUrl:c,refresh:n,source:l,state:o.getState()},i))}};t.preventDefault(),!1===o.getState().isOpen&&(r.openOnFocus||Boolean(o.getState().query))?Ce(qe({event:t,props:r,query:o.getState().query,refresh:n,store:o},i)).then((function(){o.dispatch(t.key,{nextActiveItemId:r.defaultActiveItemId}),c(),setTimeout(a,0)})):(o.dispatch(t.key,{}),c(),a())}else if("Escape"===t.key)t.preventDefault(),o.dispatch(t.key,null),o.pendingRequests.cancelAll();else if("Tab"===t.key)o.dispatch("blur",null),o.pendingRequests.cancelAll();else if("Enter"===t.key){if(null===o.getState().activeItemId||o.getState().collections.every((function(e){return 0===e.items.length})))return void(r.debug||o.pendingRequests.cancelAll());t.preventDefault();var l=ge(o.getState()),u=l.item,s=l.itemInputValue,f=l.itemUrl,m=l.source;if(t.metaKey||t.ctrlKey)void 0!==f&&(m.onSelect(qe({event:t,item:u,itemInputValue:s,itemUrl:f,refresh:n,source:m,state:o.getState()},i)),r.navigator.navigateNewTab({itemUrl:f,item:u,state:o.getState()}));else if(t.shiftKey)void 0!==f&&(m.onSelect(qe({event:t,item:u,itemInputValue:s,itemUrl:f,refresh:n,source:m,state:o.getState()},i)),r.navigator.navigateNewWindow({itemUrl:f,item:u,state:o.getState()}));else if(t.altKey);else{if(void 0!==f)return m.onSelect(qe({event:t,item:u,itemInputValue:s,itemUrl:f,refresh:n,source:m,state:o.getState()},i)),void r.navigator.navigate({itemUrl:f,item:u,state:o.getState()});Ce(qe({event:t,nextState:{isOpen:!1},props:r,query:s,refresh:n,store:o},i)).then((function(){m.onSelect(qe({event:t,item:u,itemInputValue:s,itemUrl:f,refresh:n,source:m,state:o.getState()},i))}))}}}(We({event:e,props:t,refresh:r,store:n},o))},onFocus:c,onBlur:a,onClick:function(r){e.inputElement!==t.environment.document.activeElement||n.getState().isOpen||c(r)}},f)},getPanelProps:function(e){return We({onMouseDown:function(e){e.preventDefault()},onMouseLeave:function(){n.dispatch("mouseleave",null)}},e)},getListProps:function(e){var r=e||{},n=r.sourceIndex,o=Ze(r,$e);return We({role:"listbox","aria-labelledby":"".concat(i(t.id,n),"-label"),id:"".concat(i(t.id,n),"-list")},o)},getItemProps:function(e){var a=e.item,c=e.source,l=e.sourceIndex,u=Ze(e,Je);return We({id:"".concat(i(t.id,l),"-item-").concat(a.__autocomplete_id),role:"option","aria-selected":n.getState().activeItemId===a.__autocomplete_id,onMouseMove:function(e){if(a.__autocomplete_id!==n.getState().activeItemId){n.dispatch("mousemove",a.__autocomplete_id);var t=ge(n.getState());if(null!==n.getState().activeItemId&&t){var i=t.item,c=t.itemInputValue,l=t.itemUrl,u=t.source;u.onActive(We({event:e,item:i,itemInputValue:c,itemUrl:l,refresh:r,source:u,state:n.getState()},o))}}},onMouseDown:function(e){e.preventDefault()},onClick:function(e){var i=c.getItemInputValue({item:a,state:n.getState()}),l=c.getItemUrl({item:a,state:n.getState()});(l?Promise.resolve():Ce(We({event:e,nextState:{isOpen:!1},props:t,query:i,refresh:r,store:n},o))).then((function(){c.onSelect(We({event:e,item:a,itemInputValue:i,itemUrl:l,refresh:r,source:c,state:n.getState()},o))}))}},u)}}}var Xe=[{segment:"autocomplete-core",version:"1.9.3"}];function Ye(e){return Ye="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ye(e)}function et(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function tt(e){for(var t=1;t =r?null===n?null:0:o}function at(e){return at="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},at(e)}function ct(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function lt(e){for(var t=1;t e.length)&&(t=e.length);for(var r=0,n=new Array(t);r =0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n =0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}function kt(e){var t=e.translations,r=void 0===t?{}:t,n=At(e,Pt),o=r.noResultsText,i=void 0===o?"No results for":o,a=r.suggestedQueryText,c=void 0===a?"Try searching for":a,l=r.reportMissingResultsText,u=void 0===l?"Believe this query should return results?":l,s=r.reportMissingResultsLinkText,f=void 0===s?"Let us know.":s,m=n.state.context.searchSuggestions;return yt.createElement("div",{className:"DocSearch-NoResults"},yt.createElement("div",{className:"DocSearch-Screen-Icon"},yt.createElement(Et,null)),yt.createElement("p",{className:"DocSearch-Title"},i,' "',yt.createElement("strong",null,n.state.query),'"'),m&&m.length>0&&yt.createElement("div",{className:"DocSearch-NoResults-Prefill-List"},yt.createElement("p",{className:"DocSearch-Help"},c,":"),yt.createElement("ul",null,m.slice(0,3).reduce((function(e,t){return[].concat(It(e),[yt.createElement("li",{key:t},yt.createElement("button",{className:"DocSearch-Prefill",key:t,type:"button",onClick:function(){n.setQuery(t.toLowerCase()+" "),n.refresh(),n.inputRef.current.focus()}},t))])}),[]))),n.getMissingResultsUrl&&yt.createElement("p",{className:"DocSearch-Help"},"".concat(u," "),yt.createElement("a",{href:n.getMissingResultsUrl({query:n.state.query}),target:"_blank",rel:"noopener noreferrer"},f)))}var xt=function(){return yt.createElement("svg",{width:"20",height:"20",viewBox:"0 0 20 20"},yt.createElement("path",{d:"M17 6v12c0 .52-.2 1-1 1H4c-.7 0-1-.33-1-1V2c0-.55.42-1 1-1h8l5 5zM14 8h-3.13c-.51 0-.87-.34-.87-.87V4",stroke:"currentColor",fill:"none",fillRule:"evenodd",strokeLinejoin:"round"}))};function Ct(e){switch(e.type){case"lvl1":return yt.createElement(xt,null);case"content":return yt.createElement(Nt,null);default:return yt.createElement(_t,null)}}function _t(){return yt.createElement("svg",{width:"20",height:"20",viewBox:"0 0 20 20"},yt.createElement("path",{d:"M13 13h4-4V8H7v5h6v4-4H7V8H3h4V3v5h6V3v5h4-4v5zm-6 0v4-4H3h4z",stroke:"currentColor",fill:"none",fillRule:"evenodd",strokeLinecap:"round",strokeLinejoin:"round"}))}function Nt(){return yt.createElement("svg",{width:"20",height:"20",viewBox:"0 0 20 20"},yt.createElement("path",{d:"M17 5H3h14zm0 5H3h14zm0 5H3h14z",stroke:"currentColor",fill:"none",fillRule:"evenodd",strokeLinejoin:"round"}))}function Tt(){return yt.createElement("svg",{className:"DocSearch-Hit-Select-Icon",width:"20",height:"20",viewBox:"0 0 20 20"},yt.createElement("g",{stroke:"currentColor",fill:"none",fillRule:"evenodd",strokeLinecap:"round",strokeLinejoin:"round"},yt.createElement("path",{d:"M18 3v4c0 2-2 4-4 4H2"}),yt.createElement("path",{d:"M8 17l-6-6 6-6"})))}var qt=["hit","attribute","tagName"];function Rt(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function Lt(e){for(var t=1;t =0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n =0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}function Ft(e,t){return t.split(".").reduce((function(e,t){return null!=e&&e[t]?e[t]:null}),e)}function Ut(e){var t=e.hit,r=e.attribute,n=e.tagName,o=void 0===n?"span":n,i=Ht(e,qt);return(0,yt.createElement)(o,Lt(Lt({},i),{},{dangerouslySetInnerHTML:{__html:Ft(t,"_snippetResult.".concat(r,".value"))||Ft(t,r)}}))}function Bt(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var r=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null==r)return;var n,o,i=[],a=!0,c=!1;try{for(r=r.call(e);!(a=(n=r.next()).done)&&(i.push(n.value),!t||i.length!==t);a=!0);}catch(l){c=!0,o=l}finally{try{a||null==r.return||r.return()}finally{if(c)throw o}}return i}(e,t)||function(e,t){if(!e)return;if("string"==typeof e)return Vt(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);"Object"===r&&e.constructor&&(r=e.constructor.name);if("Map"===r||"Set"===r)return Array.from(e);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Vt(e,t)}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}function Vt(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r |<\/mark>)/g,Wt=RegExp(zt.source);function Qt(e){var t,r,n=e;if(!n.__docsearch_parent&&!e._highlightResult)return e.hierarchy.lvl0;var o=((n.__docsearch_parent?null===(t=n.__docsearch_parent)||void 0===t||null===(t=t._highlightResult)||void 0===t||null===(t=t.hierarchy)||void 0===t?void 0:t.lvl0:null===(r=e._highlightResult)||void 0===r||null===(r=r.hierarchy)||void 0===r?void 0:r.lvl0)||{}).value;return o&&Wt.test(o)?o.replace(zt,""):o}function Zt(){return Zt=Object.assign||function(e){for(var t=1;t =0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n =0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}function or(e){var t=e.translations,r=void 0===t?{}:t,n=nr(e,tr),o=r.recentSearchesTitle,i=void 0===o?"Recent":o,a=r.noRecentSearchesText,c=void 0===a?"No recent searches":a,l=r.saveRecentSearchButtonTitle,u=void 0===l?"Save this search":l,s=r.removeRecentSearchButtonTitle,f=void 0===s?"Remove this search from history":s,m=r.favoriteSearchesTitle,p=void 0===m?"Favorite":m,v=r.removeFavoriteSearchButtonTitle,d=void 0===v?"Remove this search from favorites":v;return"idle"===n.state.status&&!1===n.hasCollections?n.disableUserPersonalization?null:yt.createElement("div",{className:"DocSearch-StartScreen"},yt.createElement("p",{className:"DocSearch-Help"},c)):!1===n.hasCollections?null:yt.createElement("div",{className:"DocSearch-Dropdown-Container"},yt.createElement($t,rr({},n,{title:i,collection:n.state.collections[0],renderIcon:function(){return yt.createElement("div",{className:"DocSearch-Hit-icon"},yt.createElement(Xt,null))},renderAction:function(e){var t=e.item,r=e.runFavoriteTransition,o=e.runDeleteTransition;return yt.createElement(yt.Fragment,null,yt.createElement("div",{className:"DocSearch-Hit-action"},yt.createElement("button",{className:"DocSearch-Hit-action-button",title:u,type:"submit",onClick:function(e){e.preventDefault(),e.stopPropagation(),r((function(){n.favoriteSearches.add(t),n.recentSearches.remove(t),n.refresh()}))}},yt.createElement(Yt,null))),yt.createElement("div",{className:"DocSearch-Hit-action"},yt.createElement("button",{className:"DocSearch-Hit-action-button",title:f,type:"submit",onClick:function(e){e.preventDefault(),e.stopPropagation(),o((function(){n.recentSearches.remove(t),n.refresh()}))}},yt.createElement(er,null))))}})),yt.createElement($t,rr({},n,{title:p,collection:n.state.collections[1],renderIcon:function(){return yt.createElement("div",{className:"DocSearch-Hit-icon"},yt.createElement(Yt,null))},renderAction:function(e){var t=e.item,r=e.runDeleteTransition;return yt.createElement("div",{className:"DocSearch-Hit-action"},yt.createElement("button",{className:"DocSearch-Hit-action-button",title:d,type:"submit",onClick:function(e){e.preventDefault(),e.stopPropagation(),r((function(){n.favoriteSearches.remove(t),n.refresh()}))}},yt.createElement(er,null)))}})))}var ir=["translations"];function ar(){return ar=Object.assign||function(e){for(var t=1;t =0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n =0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}var lr=yt.memo((function(e){var t=e.translations,r=void 0===t?{}:t,n=cr(e,ir);if("error"===n.state.status)return yt.createElement(wt,{translations:null==r?void 0:r.errorScreen});var o=n.state.collections.some((function(e){return e.items.length>0}));return n.state.query?!1===o?yt.createElement(kt,ar({},n,{translations:null==r?void 0:r.noResultsScreen})):yt.createElement(Gt,n):yt.createElement(or,ar({},n,{hasCollections:o,translations:null==r?void 0:r.startScreen}))}),(function(e,t){return"loading"===t.state.status||"stalled"===t.state.status}));function ur(){return yt.createElement("svg",{viewBox:"0 0 38 38",stroke:"currentColor",strokeOpacity:".5"},yt.createElement("g",{fill:"none",fillRule:"evenodd"},yt.createElement("g",{transform:"translate(1 1)",strokeWidth:"2"},yt.createElement("circle",{strokeOpacity:".3",cx:"18",cy:"18",r:"18"}),yt.createElement("path",{d:"M36 18c0-9.94-8.06-18-18-18"},yt.createElement("animateTransform",{attributeName:"transform",type:"rotate",from:"0 18 18",to:"360 18 18",dur:"1s",repeatCount:"indefinite"})))))}var sr=r(9188),fr=["translations"];function mr(){return mr=Object.assign||function(e){for(var t=1;t =0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n =0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}function vr(e){var t=e.translations,r=void 0===t?{}:t,n=pr(e,fr),o=r.resetButtonTitle,i=void 0===o?"Clear the query":o,a=r.resetButtonAriaLabel,c=void 0===a?"Clear the query":a,l=r.cancelButtonText,u=void 0===l?"Cancel":l,s=r.cancelButtonAriaLabel,f=void 0===s?"Cancel":s,m=r.searchInputLabel,p=void 0===m?"Search":m,v=n.getFormProps({inputElement:n.inputRef.current}).onReset;return yt.useEffect((function(){n.autoFocus&&n.inputRef.current&&n.inputRef.current.focus()}),[n.autoFocus,n.inputRef]),yt.useEffect((function(){n.isFromSelection&&n.inputRef.current&&n.inputRef.current.select()}),[n.isFromSelection,n.inputRef]),yt.createElement(yt.Fragment,null,yt.createElement("form",{className:"DocSearch-Form",onSubmit:function(e){e.preventDefault()},onReset:v},yt.createElement("label",mr({className:"DocSearch-MagnifierLabel"},n.getLabelProps()),yt.createElement(sr.W,null),yt.createElement("span",{className:"DocSearch-VisuallyHiddenForAccessibility"},p)),yt.createElement("div",{className:"DocSearch-LoadingIndicator"},yt.createElement(ur,null)),yt.createElement("input",mr({className:"DocSearch-Input",ref:n.inputRef},n.getInputProps({inputElement:n.inputRef.current,autoFocus:n.autoFocus,maxLength:ht}))),yt.createElement("button",{type:"reset",title:i,className:"DocSearch-Reset","aria-label":c,hidden:!n.state.query},yt.createElement(er,null))),yt.createElement("button",{className:"DocSearch-Cancel",type:"reset","aria-label":f,onClick:n.onClose},u))}var dr=["_highlightResult","_snippetResult"];function yr(e,t){if(null==e)return{};var r,n,o=function(e,t){if(null==e)return{};var r,n,o={},i=Object.keys(e);for(n=0;n =0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n =0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}function hr(e){return!1===function(){var e="__TEST_KEY__";try{return localStorage.setItem(e,""),localStorage.removeItem(e),!0}catch(t){return!1}}()?{setItem:function(){},getItem:function(){return[]}}:{setItem:function(t){return window.localStorage.setItem(e,JSON.stringify(t))},getItem:function(){var t=window.localStorage.getItem(e);return t?JSON.parse(t):[]}}}function br(e){var t=e.key,r=e.limit,n=void 0===r?5:r,o=hr(t),i=o.getItem().slice(0,n);return{add:function(e){var t=e,r=(t._highlightResult,t._snippetResult,yr(t,dr)),a=i.findIndex((function(e){return e.objectID===r.objectID}));a>-1&&i.splice(a,1),i.unshift(r),i=i.slice(0,n),o.setItem(i)},remove:function(e){i=i.filter((function(t){return t.objectID!==e.objectID})),o.setItem(i)},getAll:function(){return i}}}function gr(e){const t=`algoliasearch-client-js-${e.key}`;let r;const n=()=>(void 0===r&&(r=e.localStorage||window.localStorage),r),o=()=>JSON.parse(n().getItem(t)||"{}"),i=e=>{n().setItem(t,JSON.stringify(e))};return{get:(t,r,n={miss:()=>Promise.resolve()})=>Promise.resolve().then((()=>{(()=>{const t=e.timeToLive?1e3*e.timeToLive:null,r=o(),n=Object.fromEntries(Object.entries(r).filter((([,e])=>void 0!==e.timestamp)));if(i(n),!t)return;const a=Object.fromEntries(Object.entries(n).filter((([,e])=>{const r=(new Date).getTime();return!(e.timestamp+t Promise.all([e?e.value:r(),void 0!==e]))).then((([e,t])=>Promise.all([e,t||n.miss(e)]))).then((([e])=>e)),set:(e,r)=>Promise.resolve().then((()=>{const i=o();return i[JSON.stringify(e)]={timestamp:(new Date).getTime(),value:r},n().setItem(t,JSON.stringify(i)),r})),delete:e=>Promise.resolve().then((()=>{const r=o();delete r[JSON.stringify(e)],n().setItem(t,JSON.stringify(r))})),clear:()=>Promise.resolve().then((()=>{n().removeItem(t)}))}}function Or(e){const t=[...e.caches],r=t.shift();return void 0===r?{get:(e,t,r={miss:()=>Promise.resolve()})=>t().then((e=>Promise.all([e,r.miss(e)]))).then((([e])=>e)),set:(e,t)=>Promise.resolve(t),delete:e=>Promise.resolve(),clear:()=>Promise.resolve()}:{get:(e,n,o={miss:()=>Promise.resolve()})=>r.get(e,n,o).catch((()=>Or({caches:t}).get(e,n,o))),set:(e,n)=>r.set(e,n).catch((()=>Or({caches:t}).set(e,n))),delete:e=>r.delete(e).catch((()=>Or({caches:t}).delete(e))),clear:()=>r.clear().catch((()=>Or({caches:t}).clear()))}}function Sr(e={serializable:!0}){let t={};return{get(r,n,o={miss:()=>Promise.resolve()}){const i=JSON.stringify(r);if(i in t)return Promise.resolve(e.serializable?JSON.parse(t[i]):t[i]);const a=n(),c=o&&o.miss||(()=>Promise.resolve());return a.then((e=>c(e))).then((()=>a))},set:(r,n)=>(t[JSON.stringify(r)]=e.serializable?JSON.stringify(n):n,Promise.resolve(n)),delete:e=>(delete t[JSON.stringify(e)],Promise.resolve()),clear:()=>(t={},Promise.resolve())}}function jr(e){let t=e.length-1;for(;t>0;t--){const r=Math.floor(Math.random()*(t+1)),n=e[t];e[t]=e[r],e[r]=n}return e}function wr(e,t){return t?(Object.keys(t).forEach((r=>{e[r]=t[r](e)})),e):e}function Er(e,...t){let r=0;return e.replace(/%s/g,(()=>encodeURIComponent(t[r++])))}const Pr="4.23.3",Ir={WithinQueryParameters:0,WithinHeaders:1};function Dr(e,t){const r=e||{},n=r.data||{};return Object.keys(r).forEach((e=>{-1===["timeout","headers","queryParameters","data","cacheable"].indexOf(e)&&(n[e]=r[e])})),{data:Object.entries(n).length>0?n:void 0,timeout:r.timeout||t,headers:r.headers||{},queryParameters:r.queryParameters||{},cacheable:r.cacheable}}const Ar={Read:1,Write:2,Any:3},kr={Up:1,Down:2,Timeouted:3},xr=12e4;function Cr(e,t=kr.Up){return{...e,status:t,lastUpdate:Date.now()}}function _r(e){return"string"==typeof e?{protocol:"https",url:e,accept:Ar.Any}:{protocol:e.protocol||"https",url:e.url,accept:e.accept||Ar.Any}}const Nr={Delete:"DELETE",Get:"GET",Post:"POST",Put:"PUT"};function Tr(e,t){return Promise.all(t.map((t=>e.get(t,(()=>Promise.resolve(Cr(t))))))).then((e=>{const r=e.filter((e=>function(e){return e.status===kr.Up||Date.now()-e.lastUpdate>xr}(e))),n=e.filter((e=>function(e){return e.status===kr.Timeouted&&Date.now()-e.lastUpdate<=xr}(e))),o=[...r,...n];return{getTimeout:(e,t)=>(0===n.length&&0===e?1:n.length+3+e)*t,statelessHosts:o.length>0?o.map((e=>_r(e))):t}}))}const qr=(e,t)=>(e=>{const t=e.status;return e.isTimedOut||(({isTimedOut:e,status:t})=>!e&&!~~t)(e)||2!=~~(t/100)&&4!=~~(t/100)})(e)?t.onRetry(e):(({status:e})=>2==~~(e/100))(e)?t.onSuccess(e):t.onFail(e);function Rr(e,t,r,n){const o=[],i=function(e,t){if(e.method===Nr.Get||void 0===e.data&&void 0===t.data)return;const r=Array.isArray(e.data)?e.data:{...e.data,...t.data};return JSON.stringify(r)}(r,n),a=function(e,t){const r={...e.headers,...t.headers},n={};return Object.keys(r).forEach((e=>{const t=r[e];n[e.toLowerCase()]=t})),n}(e,n),c=r.method,l=r.method!==Nr.Get?{}:{...r.data,...n.data},u={"x-algolia-agent":e.userAgent.value,...e.queryParameters,...l,...n.queryParameters};let s=0;const f=(t,l)=>{const m=t.pop();if(void 0===m)throw{name:"RetryError",message:"Unreachable hosts - your application id may be incorrect. If the error persists, contact support@algolia.com.",transporterStackTrace:Fr(o)};const p={data:i,headers:a,method:c,url:Mr(m,r.path,u),connectTimeout:l(s,e.timeouts.connect),responseTimeout:l(s,n.timeout)},v=e=>{const r={request:p,response:e,host:m,triesLeft:t.length};return o.push(r),r},d={onSuccess:e=>function(e){try{return JSON.parse(e.content)}catch(t){throw function(e,t){return{name:"DeserializationError",message:e,response:t}}(t.message,e)}}(e),onRetry(r){const n=v(r);return r.isTimedOut&&s++,Promise.all([e.logger.info("Retryable failure",Ur(n)),e.hostsCache.set(m,Cr(m,r.isTimedOut?kr.Timeouted:kr.Down))]).then((()=>f(t,l)))},onFail(e){throw v(e),function({content:e,status:t},r){let n=e;try{n=JSON.parse(e).message}catch(o){}return function(e,t,r){return{name:"ApiError",message:e,status:t,transporterStackTrace:r}}(n,t,r)}(e,Fr(o))}};return e.requester.send(p).then((e=>qr(e,d)))};return Tr(e.hostsCache,t).then((e=>f([...e.statelessHosts].reverse(),e.getTimeout)))}function Lr(e){const t={value:`Algolia for JavaScript (${e})`,add(e){const r=`; ${e.segment}${void 0!==e.version?` (${e.version})`:""}`;return-1===t.value.indexOf(r)&&(t.value=`${t.value}${r}`),t}};return t}function Mr(e,t,r){const n=Hr(r);let o=`${e.protocol}://${e.url}/${"/"===t.charAt(0)?t.substr(1):t}`;return n.length&&(o+=`?${n}`),o}function Hr(e){return Object.keys(e).map((t=>{return Er("%s=%s",t,(r=e[t],"[object Object]"===Object.prototype.toString.call(r)||"[object Array]"===Object.prototype.toString.call(r)?JSON.stringify(e[t]):e[t]));var r})).join("&")}function Fr(e){return e.map((e=>Ur(e)))}function Ur(e){const t=e.request.headers["x-algolia-api-key"]?{"x-algolia-api-key":"*****"}:{};return{...e,request:{...e.request,headers:{...e.request.headers,...t}}}}const Br=e=>{const t=e.appId,r=function(e,t,r){const n={"x-algolia-api-key":r,"x-algolia-application-id":t};return{headers:()=>e===Ir.WithinHeaders?n:{},queryParameters:()=>e===Ir.WithinQueryParameters?n:{}}}(void 0!==e.authMode?e.authMode:Ir.WithinHeaders,t,e.apiKey),n=function(e){const{hostsCache:t,logger:r,requester:n,requestsCache:o,responsesCache:i,timeouts:a,userAgent:c,hosts:l,queryParameters:u,headers:s}=e,f={hostsCache:t,logger:r,requester:n,requestsCache:o,responsesCache:i,timeouts:a,userAgent:c,headers:s,queryParameters:u,hosts:l.map((e=>_r(e))),read(e,t){const r=Dr(t,f.timeouts.read),n=()=>Rr(f,f.hosts.filter((e=>!!(e.accept&Ar.Read))),e,r);if(!0!==(void 0!==r.cacheable?r.cacheable:e.cacheable))return n();const o={request:e,mappedRequestOptions:r,transporter:{queryParameters:f.queryParameters,headers:f.headers}};return f.responsesCache.get(o,(()=>f.requestsCache.get(o,(()=>f.requestsCache.set(o,n()).then((e=>Promise.all([f.requestsCache.delete(o),e])),(e=>Promise.all([f.requestsCache.delete(o),Promise.reject(e)]))).then((([e,t])=>t))))),{miss:e=>f.responsesCache.set(o,e)})},write:(e,t)=>Rr(f,f.hosts.filter((e=>!!(e.accept&Ar.Write))),e,Dr(t,f.timeouts.write))};return f}({hosts:[{url:`${t}-dsn.algolia.net`,accept:Ar.Read},{url:`${t}.algolia.net`,accept:Ar.Write}].concat(jr([{url:`${t}-1.algolianet.com`},{url:`${t}-2.algolianet.com`},{url:`${t}-3.algolianet.com`}])),...e,headers:{...r.headers(),"content-type":"application/x-www-form-urlencoded",...e.headers},queryParameters:{...r.queryParameters(),...e.queryParameters}}),o={transporter:n,appId:t,addAlgoliaAgent(e,t){n.userAgent.add({segment:e,version:t})},clearCache:()=>Promise.all([n.requestsCache.clear(),n.responsesCache.clear()]).then((()=>{}))};return wr(o,e.methods)},Vr=e=>(t,r)=>t.method===Nr.Get?e.transporter.read(t,r):e.transporter.write(t,r),Kr=e=>(t,r={})=>wr({transporter:e.transporter,appId:e.appId,indexName:t},r.methods),$r=e=>(t,r)=>{const n=t.map((e=>({...e,params:Hr(e.params||{})})));return e.transporter.read({method:Nr.Post,path:"1/indexes/*/queries",data:{requests:n},cacheable:!0},r)},Jr=e=>(t,r)=>Promise.all(t.map((t=>{const{facetName:n,facetQuery:o,...i}=t.params;return Kr(e)(t.indexName,{methods:{searchForFacetValues:Qr}}).searchForFacetValues(n,o,{...r,...i})}))),zr=e=>(t,r,n)=>e.transporter.read({method:Nr.Post,path:Er("1/answers/%s/prediction",e.indexName),data:{query:t,queryLanguages:r},cacheable:!0},n),Wr=e=>(t,r)=>e.transporter.read({method:Nr.Post,path:Er("1/indexes/%s/query",e.indexName),data:{query:t},cacheable:!0},r),Qr=e=>(t,r,n)=>e.transporter.read({method:Nr.Post,path:Er("1/indexes/%s/facets/%s/query",e.indexName,t),data:{facetQuery:r},cacheable:!0},n),Zr={Debug:1,Info:2,Error:3};const Gr=e=>(t,r)=>{const n=t.map((e=>({...e,threshold:e.threshold||0})));return e.transporter.read({method:Nr.Post,path:"1/indexes/*/recommendations",data:{requests:n},cacheable:!0},r)};function Xr(e,t,r){const n={appId:e,apiKey:t,timeouts:{connect:1,read:2,write:30},requester:{send:e=>new Promise((t=>{const r=new XMLHttpRequest;r.open(e.method,e.url,!0),Object.keys(e.headers).forEach((t=>r.setRequestHeader(t,e.headers[t])));const n=(e,n)=>setTimeout((()=>{r.abort(),t({status:0,content:n,isTimedOut:!0})}),1e3*e),o=n(e.connectTimeout,"Connection timeout");let i;r.onreadystatechange=()=>{r.readyState>r.OPENED&&void 0===i&&(clearTimeout(o),i=n(e.responseTimeout,"Socket timeout"))},r.onerror=()=>{0===r.status&&(clearTimeout(o),clearTimeout(i),t({content:r.responseText||"Network request failed",status:r.status,isTimedOut:!1}))},r.onload=()=>{clearTimeout(o),clearTimeout(i),t({content:r.responseText,status:r.status,isTimedOut:!1})},r.send(e.data)}))},logger:(o=Zr.Error,{debug:(e,t)=>(Zr.Debug>=o&&console.debug(e,t),Promise.resolve()),info:(e,t)=>(Zr.Info>=o&&console.info(e,t),Promise.resolve()),error:(e,t)=>(console.error(e,t),Promise.resolve())}),responsesCache:Sr(),requestsCache:Sr({serializable:!1}),hostsCache:Or({caches:[gr({key:`${Pr}-${e}`}),Sr()]}),userAgent:Lr(Pr).add({segment:"Browser",version:"lite"}),authMode:Ir.WithinQueryParameters};var o;return Br({...n,...r,methods:{search:$r,searchForFacetValues:Jr,multipleQueries:$r,multipleSearchForFacetValues:Jr,customRequest:Vr,initIndex:e=>t=>Kr(e)(t,{methods:{search:Wr,searchForFacetValues:Qr,findAnswers:zr}}),getRecommendations:Gr}})}Xr.version=Pr;const Yr=Xr;var en="3.6.0";function tn(){}function rn(e){return e}function nn(e){return 1===e.button||e.altKey||e.ctrlKey||e.metaKey||e.shiftKey}function on(e,t,r){return e.reduce((function(e,n){var o=t(n);return e.hasOwnProperty(o)||(e[o]=[]),e[o].length<(r||5)&&e[o].push(n),e}),{})}var an=["footer","searchBox"];function cn(){return cn=Object.assign||function(e){for(var t=1;t e.length)&&(t=e.length);for(var r=0,n=new Array(t);r =0||(o[r]=e[r]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(n=0;n =0||Object.prototype.propertyIsEnumerable.call(e,r)&&(o[r]=e[r])}return o}function vn(e){var t=e.appId,r=e.apiKey,n=e.indexName,o=e.placeholder,i=void 0===o?"Search docs":o,a=e.searchParameters,c=e.maxResultsPerGroup,l=e.onClose,u=void 0===l?tn:l,s=e.transformItems,f=void 0===s?rn:s,m=e.hitComponent,p=void 0===m?St:m,v=e.resultsFooterComponent,d=void 0===v?function(){return null}:v,y=e.navigator,h=e.initialScrollY,b=void 0===h?0:h,g=e.transformSearchClient,O=void 0===g?rn:g,S=e.disableUserPersonalization,j=void 0!==S&&S,w=e.initialQuery,E=void 0===w?"":w,P=e.translations,I=void 0===P?{}:P,D=e.getMissingResultsUrl,A=e.insights,k=void 0!==A&&A,x=I.footer,C=I.searchBox,_=pn(I,an),N=fn(yt.useState({query:"",collections:[],completion:null,context:{},isOpen:!1,activeItemId:null,status:"idle"}),2),T=N[0],q=N[1],R=yt.useRef(null),L=yt.useRef(null),M=yt.useRef(null),H=yt.useRef(null),F=yt.useRef(null),U=yt.useRef(10),B=yt.useRef("undefined"!=typeof window?window.getSelection().toString().slice(0,ht):"").current,V=yt.useRef(E||B).current,K=function(e,t,r){return yt.useMemo((function(){var n=Yr(e,t);return n.addAlgoliaAgent("docsearch",en),!1===/docsearch.js \(.*\)/.test(n.transporter.userAgent.value)&&n.addAlgoliaAgent("docsearch-react",en),r(n)}),[e,t,r])}(t,r,O),$=yt.useRef(br({key:"__DOCSEARCH_FAVORITE_SEARCHES__".concat(n),limit:10})).current,J=yt.useRef(br({key:"__DOCSEARCH_RECENT_SEARCHES__".concat(n),limit:0===$.getAll().length?7:4})).current,z=yt.useCallback((function(e){if(!j){var t="content"===e.type?e.__docsearch_parent:e;t&&-1===$.getAll().findIndex((function(e){return e.objectID===t.objectID}))&&J.add(t)}}),[$,J,j]),W=yt.useCallback((function(e){if(T.context.algoliaInsightsPlugin&&e.__autocomplete_id){var t=e,r={eventName:"Item Selected",index:t.__autocomplete_indexName,items:[t],positions:[e.__autocomplete_id],queryID:t.__autocomplete_queryID};T.context.algoliaInsightsPlugin.insights.clickedObjectIDsAfterSearch(r)}}),[T.context.algoliaInsightsPlugin]),Q=yt.useMemo((function(){return dt({id:"docsearch",defaultActiveItemId:0,placeholder:i,openOnFocus:!0,initialState:{query:V,context:{searchSuggestions:[]}},insights:k,navigator:y,onStateChange:function(e){q(e.state)},getSources:function(e){var o=e.query,i=e.state,l=e.setContext,s=e.setStatus;if(!o)return j?[]:[{sourceId:"recentSearches",onSelect:function(e){var t=e.item,r=e.event;z(t),nn(r)||u()},getItemUrl:function(e){return e.item.url},getItems:function(){return J.getAll()}},{sourceId:"favoriteSearches",onSelect:function(e){var t=e.item,r=e.event;z(t),nn(r)||u()},getItemUrl:function(e){return e.item.url},getItems:function(){return $.getAll()}}];var m=Boolean(k);return K.search([{query:o,indexName:n,params:un({attributesToRetrieve:["hierarchy.lvl0","hierarchy.lvl1","hierarchy.lvl2","hierarchy.lvl3","hierarchy.lvl4","hierarchy.lvl5","hierarchy.lvl6","content","type","url"],attributesToSnippet:["hierarchy.lvl1:".concat(U.current),"hierarchy.lvl2:".concat(U.current),"hierarchy.lvl3:".concat(U.current),"hierarchy.lvl4:".concat(U.current),"hierarchy.lvl5:".concat(U.current),"hierarchy.lvl6:".concat(U.current),"content:".concat(U.current)],snippetEllipsisText:"\u2026",highlightPreTag:"",highlightPostTag:"",hitsPerPage:20,clickAnalytics:m},a)}]).catch((function(e){throw"RetryError"===e.name&&s("error"),e})).then((function(e){var o=e.results[0],a=o.hits,s=o.nbHits,p=on(a,(function(e){return Qt(e)}),c);i.context.searchSuggestions.length 0&&(X(),F.current&&F.current.focus())}),[V,X]),yt.useEffect((function(){function e(){if(L.current){var e=.01*window.innerHeight;L.current.style.setProperty("--docsearch-vh","".concat(e,"px"))}}return e(),window.addEventListener("resize",e),function(){window.removeEventListener("resize",e)}}),[]),yt.createElement("div",cn({ref:R},G({"aria-expanded":!0}),{className:["DocSearch","DocSearch-Container","stalled"===T.status&&"DocSearch-Container--Stalled","error"===T.status&&"DocSearch-Container--Errored"].filter(Boolean).join(" "),role:"button",tabIndex:0,onMouseDown:function(e){e.target===e.currentTarget&&u()}}),yt.createElement("div",{className:"DocSearch-Modal",ref:L},yt.createElement("header",{className:"DocSearch-SearchBar",ref:M},yt.createElement(vr,cn({},Q,{state:T,autoFocus:0===V.length,inputRef:F,isFromSelection:Boolean(V)&&V===B,translations:C,onClose:u}))),yt.createElement("div",{className:"DocSearch-Dropdown",ref:H},yt.createElement(lr,cn({},Q,{indexName:n,state:T,hitComponent:p,resultsFooterComponent:d,disableUserPersonalization:j,recentSearches:J,favoriteSearches:$,inputRef:F,translations:_,getMissingResultsUrl:D,onItemClick:function(e,t){W(e),z(e),nn(t)||u()}}))),yt.createElement("footer",{className:"DocSearch-Footer"},yt.createElement(Ot,{translations:x}))))}}}]); \ No newline at end of file diff --git a/assets/js/9693de07.54a97dfa.js b/assets/js/9693de07.54a97dfa.js deleted file mode 100644 index 8ddc90238..000000000 --- a/assets/js/9693de07.54a97dfa.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[656],{7645:(e,n,r)=>{r.r(n),r.d(n,{assets:()=>c,contentTitle:()=>l,default:()=>a,frontMatter:()=>d,metadata:()=>t,toc:()=>o});var s=r(4848),i=r(8453);const d={id:"Dependencies",title:"Interface: Dependencies",sidebar_label:"Dependencies",sidebar_position:0,custom_edit_url:null},l=void 0,t={id:"api/interfaces/Dependencies",title:"Interface: Dependencies",description:"Properties",source:"@site/docs/api/interfaces/Dependencies.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/Dependencies",permalink:"/docs/api/interfaces/Dependencies",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"Dependencies",title:"Interface: Dependencies",sidebar_label:"Dependencies",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"CoreModuleStore",permalink:"/docs/api/interfaces/CoreModuleStore"},next:{title:"DependencyConfiguration",permalink:"/docs/api/interfaces/DependencyConfiguration"}},c={},o=[{value:"Properties",id:"properties",level:2},{value:"@sern/client",id:"sernclient",level:3},{value:"Defined in",id:"defined-in",level:4},{value:"@sern/emitter",id:"sernemitter",level:3},{value:"Defined in",id:"defined-in-1",level:4},{value:"@sern/errors",id:"sernerrors",level:3},{value:"Defined in",id:"defined-in-2",level:4},{value:"@sern/logger",id:"sernlogger",level:3},{value:"Defined in",id:"defined-in-3",level:4},{value:"@sern/modules",id:"sernmodules",level:3},{value:"Defined in",id:"defined-in-4",level:4},{value:"@sern/store",id:"sernstore",level:3},{value:"Defined in",id:"defined-in-5",level:4}];function h(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",hr:"hr",p:"p",strong:"strong",...(0,i.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,s.jsx)(n.h3,{id:"sernclient",children:"@sern/client"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.strong,{children:"@sern/client"}),": ",(0,s.jsx)(n.a,{href:"/docs/api/modules#singleton",children:(0,s.jsx)(n.code,{children:"Singleton"})}),"<",(0,s.jsx)(n.code,{children:"__module"}),">"]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/types/handler.ts#L40",children:"src/types/handler.ts:40"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"sernemitter",children:"@sern/emitter"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.strong,{children:"@sern/emitter"}),": ",(0,s.jsx)(n.a,{href:"/docs/api/modules#singleton",children:(0,s.jsx)(n.code,{children:"Singleton"})}),"<",(0,s.jsx)(n.a,{href:"../classes/SernEmitter.md",children:(0,s.jsx)(n.code,{children:"SernEmitter"})}),">"]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/types/handler.ts#L42",children:"src/types/handler.ts:42"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"sernerrors",children:"@sern/errors"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.strong,{children:"@sern/errors"}),": ",(0,s.jsx)(n.a,{href:"/docs/api/modules#singleton",children:(0,s.jsx)(n.code,{children:"Singleton"})}),"<",(0,s.jsx)(n.a,{href:"ErrorHandling.md",children:(0,s.jsx)(n.code,{children:"ErrorHandling"})}),">"]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/types/handler.ts#L45",children:"src/types/handler.ts:45"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"sernlogger",children:"@sern/logger"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"Optional"})," ",(0,s.jsx)(n.strong,{children:"@sern/logger"}),": ",(0,s.jsx)(n.a,{href:"/docs/api/modules#singleton",children:(0,s.jsx)(n.code,{children:"Singleton"})}),"<",(0,s.jsx)(n.a,{href:"Logging.md",children:(0,s.jsx)(n.code,{children:"Logging"})}),"<",(0,s.jsx)(n.code,{children:"unknown"}),">>"]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/types/handler.ts#L41",children:"src/types/handler.ts:41"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"sernmodules",children:"@sern/modules"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.strong,{children:"@sern/modules"}),": ",(0,s.jsx)(n.a,{href:"/docs/api/modules#singleton",children:(0,s.jsx)(n.code,{children:"Singleton"})}),"<",(0,s.jsx)(n.a,{href:"ModuleManager.md",children:(0,s.jsx)(n.code,{children:"ModuleManager"})}),">"]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-4",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/types/handler.ts#L44",children:"src/types/handler.ts:44"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"sernstore",children:"@sern/store"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.strong,{children:"@sern/store"}),": ",(0,s.jsx)(n.a,{href:"/docs/api/modules#singleton",children:(0,s.jsx)(n.code,{children:"Singleton"})}),"<",(0,s.jsx)(n.a,{href:"../classes/ModuleStore.md",children:(0,s.jsx)(n.code,{children:"ModuleStore"})}),">"]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-5",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/types/handler.ts#L43",children:"src/types/handler.ts:43"})})]})}function a(e={}){const{wrapper:n}={...(0,i.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(h,{...e})}):h(e)}},8453:(e,n,r)=>{r.d(n,{R:()=>l,x:()=>t});var s=r(6540);const i={},d=s.createContext(i);function l(e){const n=s.useContext(d);return s.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function t(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(i):e.components||i:l(e.components),s.createElement(d.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/97c22b42.2b330fbe.js b/assets/js/97c22b42.2b330fbe.js deleted file mode 100644 index 89a731058..000000000 --- a/assets/js/97c22b42.2b330fbe.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[7374],{5787:(e,n,i)=>{i.r(n),i.d(n,{assets:()=>c,contentTitle:()=>s,default:()=>a,frontMatter:()=>l,metadata:()=>t,toc:()=>h});var r=i(4848),d=i(8453);const l={id:"StringSelectCommand",title:"Interface: StringSelectCommand",sidebar_label:"StringSelectCommand",sidebar_position:0,custom_edit_url:null},s=void 0,t={id:"api/interfaces/StringSelectCommand",title:"Interface: StringSelectCommand",description:"Hierarchy",source:"@site/docs/api/interfaces/StringSelectCommand.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/StringSelectCommand",permalink:"/docs/api/interfaces/StringSelectCommand",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"StringSelectCommand",title:"Interface: StringSelectCommand",sidebar_label:"StringSelectCommand",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"SlashCommand",permalink:"/docs/api/interfaces/SlashCommand"},next:{title:"TextCommand",permalink:"/docs/api/interfaces/TextCommand"}},c={},h=[{value:"Hierarchy",id:"hierarchy",level:2},{value:"Properties",id:"properties",level:2},{value:"description",id:"description",level:3},{value:"Inherited from",id:"inherited-from",level:4},{value:"Defined in",id:"defined-in",level:4},{value:"execute",id:"execute",level:3},{value:"Type declaration",id:"type-declaration",level:4},{value:"Parameters",id:"parameters",level:5},{value:"Returns",id:"returns",level:5},{value:"Overrides",id:"overrides",level:4},{value:"Defined in",id:"defined-in-1",level:4},{value:"name",id:"name",level:3},{value:"Inherited from",id:"inherited-from-1",level:4},{value:"Defined in",id:"defined-in-2",level:4},{value:"onEvent",id:"onevent",level:3},{value:"Inherited from",id:"inherited-from-2",level:4},{value:"Defined in",id:"defined-in-3",level:4},{value:"plugins",id:"plugins",level:3},{value:"Inherited from",id:"inherited-from-3",level:4},{value:"Defined in",id:"defined-in-4",level:4},{value:"type",id:"type",level:3},{value:"Overrides",id:"overrides-1",level:4},{value:"Defined in",id:"defined-in-5",level:4}];function o(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",h5:"h5",hr:"hr",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,d.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(n.h2,{id:"hierarchy",children:"Hierarchy"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"Module"})}),"\n",(0,r.jsxs)(n.p,{children:["\u21b3 ",(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"StringSelectCommand"})})]}),"\n"]}),"\n"]}),"\n",(0,r.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,r.jsx)(n.h3,{id:"description",children:"description"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"description"}),": ",(0,r.jsx)(n.code,{children:"string"})]}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"Module.description"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L36",children:"src/types/core-modules.ts:36"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"execute",children:"execute"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"execute"}),": (",(0,r.jsx)(n.code,{children:"ctx"}),": ",(0,r.jsx)(n.code,{children:"StringSelectMenuInteraction"}),"<",(0,r.jsx)(n.code,{children:"CacheType"}),">) => ",(0,r.jsx)(n.code,{children:"unknown"})]}),"\n",(0,r.jsx)(n.h4,{id:"type-declaration",children:"Type declaration"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 (",(0,r.jsx)(n.code,{children:"ctx"}),"): ",(0,r.jsx)(n.code,{children:"unknown"})]}),"\n",(0,r.jsx)(n.h5,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsx)(n.tbody,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"ctx"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"StringSelectMenuInteraction"}),"<",(0,r.jsx)(n.code,{children:"CacheType"}),">"]})]})})]}),"\n",(0,r.jsx)(n.h5,{id:"returns",children:"Returns"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.code,{children:"unknown"})}),"\n",(0,r.jsx)(n.h4,{id:"overrides",children:"Overrides"}),"\n",(0,r.jsx)(n.p,{children:"Module.execute"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L70",children:"src/types/core-modules.ts:70"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"name",children:"name"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"name"}),": ",(0,r.jsx)(n.code,{children:"string"})]}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-1",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"Module.name"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L33",children:"src/types/core-modules.ts:33"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"onevent",children:"onEvent"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"onEvent"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/ControlPlugin",children:(0,r.jsx)(n.code,{children:"ControlPlugin"})}),"<",(0,r.jsx)(n.code,{children:"any"}),"[]>[]"]}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-2",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"Module.onEvent"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L34",children:"src/types/core-modules.ts:34"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"plugins",children:"plugins"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"plugins"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/InitPlugin",children:(0,r.jsx)(n.code,{children:"InitPlugin"})}),"<",(0,r.jsx)(n.code,{children:"any"}),"[]>[]"]}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-3",children:"Inherited from"}),"\n",(0,r.jsx)(n.p,{children:"Module.plugins"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-4",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L35",children:"src/types/core-modules.ts:35"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"type",children:"type"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"type"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/enums/CommandType#stringselect",children:(0,r.jsx)(n.code,{children:"StringSelect"})})]}),"\n",(0,r.jsx)(n.h4,{id:"overrides-1",children:"Overrides"}),"\n",(0,r.jsx)(n.p,{children:"Module.type"}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-5",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L69",children:"src/types/core-modules.ts:69"})})]})}function a(e={}){const{wrapper:n}={...(0,d.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(o,{...e})}):o(e)}},8453:(e,n,i)=>{i.d(n,{R:()=>s,x:()=>t});var r=i(6540);const d={},l=r.createContext(d);function s(e){const n=r.useContext(l);return r.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function t(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(d):e.components||d:s(e.components),r.createElement(l.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/981f6151.a5d396f1.js b/assets/js/981f6151.a5d396f1.js deleted file mode 100644 index f02fd1151..000000000 --- a/assets/js/981f6151.a5d396f1.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[6052],{5982:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>r,contentTitle:()=>d,default:()=>c,frontMatter:()=>a,metadata:()=>i,toc:()=>l});var s=t(4848),o=t(8453);const a={sidebar_position:4},d="First Command",i={id:"guide/walkthrough/first-command",title:"First Command",description:"We will dissect a basic command.",source:"@site/docs/guide/walkthrough/first-command.md",sourceDirName:"guide/walkthrough",slug:"/guide/walkthrough/first-command",permalink:"/docs/guide/walkthrough/first-command",draft:!1,unlisted:!1,editUrl:"https://github.com/sern-handler/website/edit/main/docs/guide/walkthrough/first-command.md",tags:[],version:"current",sidebarPosition:4,frontMatter:{sidebar_position:4},sidebar:"tutorialSidebar",previous:{title:"Transition from v2 to v3",permalink:"/docs/guide/walkthrough/transition"},next:{title:"First Event Module",permalink:"/docs/guide/walkthrough/first-event"}},r={},l=[{value:"Types of command modules",id:"types-of-command-modules",level:3}];function m(e){const n={a:"a",admonition:"admonition",br:"br",code:"code",h1:"h1",h3:"h3",li:"li",p:"p",pre:"pre",strong:"strong",tabitem:"tabitem",tabs:"tabs",ul:"ul",...(0,o.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.h1,{id:"first-command",children:"First Command"}),"\n",(0,s.jsxs)(n.p,{children:["We will dissect a basic command.\nIf you installed a new project via the cli, This is the ",(0,s.jsx)(n.code,{children:"ping"})," command located in src/commands folder."]}),"\n",(0,s.jsx)(n.admonition,{type:"tip",children:(0,s.jsx)(n.p,{children:"TLDR: command modules are discord bot commands. There are many types, and each one will correspond to an event from discord.\nFor example, CommandType.Slash commands will listen to slash command interactions."})}),"\n",(0,s.jsx)(n.p,{children:"import Tabs from '@theme/Tabs';\nimport TabItem from '@theme/TabItem';"}),"\n",(0,s.jsxs)(n.tabs,{children:["\n",(0,s.jsxs)(n.tabitem,{value:"js",label:"JavaScript",children:["\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-js",children:"const { CommandType, commandModule } = require('@sern/handler');\n\nexport default commandModule({\n\ttype: CommandType.Both,\n\tplugins: [],\n\tdescription: 'A ping command',\n\t// alias : [],\n\texecute: async (ctx, args) => {\n\t\tawait ctx.reply('Pong \ud83c\udfd3');\n\t},\n})\n"})}),"\n"]}),"\n",(0,s.jsxs)(n.tabitem,{value:"ts",label:"Typescript",children:["\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-ts",children:"import { commandModule, CommandType } from '@sern/handler';\n\nexport default commandModule({\n\ttype: CommandType.Both,\n\tplugins: [],\n\tdescription: 'A ping command',\n\t// alias : [],\n\texecute: async (ctx, args) => {\n\t\tawait ctx.reply({ content: 'Pong \ud83c\udfd3' });\n\t},\n});\n\n"})}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(n.p,{children:["To view what each of these properties mean in depth, visit the ",(0,s.jsx)(n.a,{href:"https://sern.dev/docs/api/enums/CommandType",children:"official documentation"}),"."]}),"\n",(0,s.jsx)(n.h3,{id:"types-of-command-modules",children:"Types of command modules"}),"\n",(0,s.jsxs)(n.p,{children:["Every command module ",(0,s.jsx)(n.code,{children:"type"})," is part of an enum. This field allows type inference for the rest of a module's fields. ",(0,s.jsx)(n.br,{}),"\nAll the command types can be found in the ",(0,s.jsx)(n.a,{href:"https://sern.dev/docs/api/enums/CommandType",children:"official documentation"}),"!"]}),"\n",(0,s.jsx)(n.p,{children:"So, lets say you want to make a command module that listens to modals. "}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.strong,{children:"Note"}),": Keep in mind you'll need to send a modal with a custom id ",(0,s.jsx)(n.code,{children:"dm-me"}),". This example below is the response to a modal being sent.\n",(0,s.jsx)(n.br,{})]}),"\n",(0,s.jsxs)(n.tabs,{children:["\n",(0,s.jsxs)(n.tabitem,{value:"js",label:"JavaScript",children:["\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-javascript",children:"const { CommandType, commandModule } = require('@sern/handler');\nexports.default = commandModule({\n name: 'dm-me',\n type: CommandType.Modal,\n async execute (modal) {\n const value = modal.fields.getTextInputValue('message');\n modal.client.users.fetch('182326315813306368').then( u =>\n u.send(value + ` from ${modal.user}`)\n );\n modal.reply( { ephemeral:true, content: 'Sent' })\n }\n});\n"})}),"\n"]}),"\n",(0,s.jsxs)(n.tabitem,{value:"ts",label:"Typescript",children:["\n",(0,s.jsx)(n.pre,{children:(0,s.jsx)(n.code,{className:"language-typescript",children:"import { commandModule, CommandType } from '@sern/handler';\nexport default commandModule({\n name: 'dm-me',\n type: CommandType.Modal,\n async execute (modal) {\n const value = modal.fields.getTextInputValue('message');\n modal.client.users.fetch('182326315813306368').then( u =>\n u.send(value + ` from ${modal.user}`)\n );\n modal.reply( { ephemeral:true, content: 'Sent' })\n }\n});\n"})}),"\n"]}),"\n"]}),"\n",(0,s.jsxs)(n.p,{children:["Commands are straight forward. Keep in mind, every other property on the commandModule object is\noptional ",(0,s.jsx)(n.strong,{children:"except"})," the type and execute function."]}),"\n",(0,s.jsx)(n.h1,{id:"context-class",children:"Context class"}),"\n",(0,s.jsxs)(n.p,{children:["The provided Context class helps with modules of ",(0,s.jsx)(n.code,{children:"CommandType.Both"})," (A mixture of slash / legacy commands)."]}),"\n",(0,s.jsx)(n.p,{children:"The Context class is passed into modules with type:"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.code,{children:"CommandType.Both"})}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.code,{children:"CommandType.Slash"})}),"\n",(0,s.jsx)(n.li,{children:(0,s.jsx)(n.code,{children:"CommandType.Text"})}),"\n"]}),"\n",(0,s.jsx)(n.p,{children:"This data structure helps interop between legacy commands and slash commands with ease."})]})}function c(e={}){const{wrapper:n}={...(0,o.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(m,{...e})}):m(e)}},8453:(e,n,t)=>{t.d(n,{R:()=>d,x:()=>i});var s=t(6540);const o={},a=s.createContext(o);function d(e){const n=s.useContext(a);return s.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function i(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(o):e.components||o:d(e.components),s.createElement(a.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/9b620520.c4e90e6c.js b/assets/js/9b620520.c4e90e6c.js deleted file mode 100644 index c82dfbc35..000000000 --- a/assets/js/9b620520.c4e90e6c.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[6193],{2423:(e,n,i)=>{i.r(n),i.d(n,{assets:()=>c,contentTitle:()=>s,default:()=>a,frontMatter:()=>t,metadata:()=>l,toc:()=>o});var d=i(4848),r=i(8453);const t={id:"ButtonCommand",title:"Interface: ButtonCommand",sidebar_label:"ButtonCommand",sidebar_position:0,custom_edit_url:null},s=void 0,l={id:"api/interfaces/ButtonCommand",title:"Interface: ButtonCommand",description:"Hierarchy",source:"@site/docs/api/interfaces/ButtonCommand.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/ButtonCommand",permalink:"/docs/api/interfaces/ButtonCommand",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"ButtonCommand",title:"Interface: ButtonCommand",sidebar_label:"ButtonCommand",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"BothCommand",permalink:"/docs/api/interfaces/BothCommand"},next:{title:"ChannelSelectCommand",permalink:"/docs/api/interfaces/ChannelSelectCommand"}},c={},o=[{value:"Hierarchy",id:"hierarchy",level:2},{value:"Properties",id:"properties",level:2},{value:"description",id:"description",level:3},{value:"Inherited from",id:"inherited-from",level:4},{value:"Defined in",id:"defined-in",level:4},{value:"execute",id:"execute",level:3},{value:"Type declaration",id:"type-declaration",level:4},{value:"Parameters",id:"parameters",level:5},{value:"Returns",id:"returns",level:5},{value:"Overrides",id:"overrides",level:4},{value:"Defined in",id:"defined-in-1",level:4},{value:"name",id:"name",level:3},{value:"Inherited from",id:"inherited-from-1",level:4},{value:"Defined in",id:"defined-in-2",level:4},{value:"onEvent",id:"onevent",level:3},{value:"Inherited from",id:"inherited-from-2",level:4},{value:"Defined in",id:"defined-in-3",level:4},{value:"plugins",id:"plugins",level:3},{value:"Inherited from",id:"inherited-from-3",level:4},{value:"Defined in",id:"defined-in-4",level:4},{value:"type",id:"type",level:3},{value:"Overrides",id:"overrides-1",level:4},{value:"Defined in",id:"defined-in-5",level:4}];function h(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",h5:"h5",hr:"hr",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,r.R)(),...e.components};return(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(n.h2,{id:"hierarchy",children:"Hierarchy"}),"\n",(0,d.jsxs)(n.ul,{children:["\n",(0,d.jsxs)(n.li,{children:["\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.code,{children:"Module"})}),"\n",(0,d.jsxs)(n.p,{children:["\u21b3 ",(0,d.jsx)(n.strong,{children:(0,d.jsx)(n.code,{children:"ButtonCommand"})})]}),"\n"]}),"\n"]}),"\n",(0,d.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,d.jsx)(n.h3,{id:"description",children:"description"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.code,{children:"Optional"})," ",(0,d.jsx)(n.strong,{children:"description"}),": ",(0,d.jsx)(n.code,{children:"string"})]}),"\n",(0,d.jsx)(n.h4,{id:"inherited-from",children:"Inherited from"}),"\n",(0,d.jsx)(n.p,{children:"Module.description"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L36",children:"src/types/core-modules.ts:36"})}),"\n",(0,d.jsx)(n.hr,{}),"\n",(0,d.jsx)(n.h3,{id:"execute",children:"execute"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.strong,{children:"execute"}),": (",(0,d.jsx)(n.code,{children:"ctx"}),": ",(0,d.jsx)(n.code,{children:"ButtonInteraction"}),"<",(0,d.jsx)(n.code,{children:"CacheType"}),">) => ",(0,d.jsx)(n.code,{children:"unknown"})]}),"\n",(0,d.jsx)(n.h4,{id:"type-declaration",children:"Type declaration"}),"\n",(0,d.jsxs)(n.p,{children:["\u25b8 (",(0,d.jsx)(n.code,{children:"ctx"}),"): ",(0,d.jsx)(n.code,{children:"unknown"})]}),"\n",(0,d.jsx)(n.h5,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,d.jsxs)(n.table,{children:[(0,d.jsx)(n.thead,{children:(0,d.jsxs)(n.tr,{children:[(0,d.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,d.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,d.jsx)(n.tbody,{children:(0,d.jsxs)(n.tr,{children:[(0,d.jsx)(n.td,{style:{textAlign:"left"},children:(0,d.jsx)(n.code,{children:"ctx"})}),(0,d.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,d.jsx)(n.code,{children:"ButtonInteraction"}),"<",(0,d.jsx)(n.code,{children:"CacheType"}),">"]})]})})]}),"\n",(0,d.jsx)(n.h5,{id:"returns",children:"Returns"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.code,{children:"unknown"})}),"\n",(0,d.jsx)(n.h4,{id:"overrides",children:"Overrides"}),"\n",(0,d.jsx)(n.p,{children:"Module.execute"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L65",children:"src/types/core-modules.ts:65"})}),"\n",(0,d.jsx)(n.hr,{}),"\n",(0,d.jsx)(n.h3,{id:"name",children:"name"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.code,{children:"Optional"})," ",(0,d.jsx)(n.strong,{children:"name"}),": ",(0,d.jsx)(n.code,{children:"string"})]}),"\n",(0,d.jsx)(n.h4,{id:"inherited-from-1",children:"Inherited from"}),"\n",(0,d.jsx)(n.p,{children:"Module.name"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L33",children:"src/types/core-modules.ts:33"})}),"\n",(0,d.jsx)(n.hr,{}),"\n",(0,d.jsx)(n.h3,{id:"onevent",children:"onEvent"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.strong,{children:"onEvent"}),": ",(0,d.jsx)(n.a,{href:"/docs/api/interfaces/ControlPlugin",children:(0,d.jsx)(n.code,{children:"ControlPlugin"})}),"<",(0,d.jsx)(n.code,{children:"any"}),"[]>[]"]}),"\n",(0,d.jsx)(n.h4,{id:"inherited-from-2",children:"Inherited from"}),"\n",(0,d.jsx)(n.p,{children:"Module.onEvent"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L34",children:"src/types/core-modules.ts:34"})}),"\n",(0,d.jsx)(n.hr,{}),"\n",(0,d.jsx)(n.h3,{id:"plugins",children:"plugins"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.strong,{children:"plugins"}),": ",(0,d.jsx)(n.a,{href:"/docs/api/interfaces/InitPlugin",children:(0,d.jsx)(n.code,{children:"InitPlugin"})}),"<",(0,d.jsx)(n.code,{children:"any"}),"[]>[]"]}),"\n",(0,d.jsx)(n.h4,{id:"inherited-from-3",children:"Inherited from"}),"\n",(0,d.jsx)(n.p,{children:"Module.plugins"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in-4",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L35",children:"src/types/core-modules.ts:35"})}),"\n",(0,d.jsx)(n.hr,{}),"\n",(0,d.jsx)(n.h3,{id:"type",children:"type"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.strong,{children:"type"}),": ",(0,d.jsx)(n.a,{href:"/docs/api/enums/CommandType#button",children:(0,d.jsx)(n.code,{children:"Button"})})]}),"\n",(0,d.jsx)(n.h4,{id:"overrides-1",children:"Overrides"}),"\n",(0,d.jsx)(n.p,{children:"Module.type"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in-5",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L64",children:"src/types/core-modules.ts:64"})})]})}function a(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,d.jsx)(n,{...e,children:(0,d.jsx)(h,{...e})}):h(e)}},8453:(e,n,i)=>{i.d(n,{R:()=>s,x:()=>l});var d=i(6540);const r={},t=d.createContext(r);function s(e){const n=d.useContext(t);return d.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function l(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(r):e.components||r:s(e.components),d.createElement(t.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/9c021584.ed65ee60.js b/assets/js/9c021584.ed65ee60.js deleted file mode 100644 index 46c25214f..000000000 --- a/assets/js/9c021584.ed65ee60.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[1307],{5173:e=>{e.exports=JSON.parse('{"permalink":"/blog/tags/release","page":1,"postsPerPage":10,"totalPages":1,"totalCount":4,"blogDescription":"Blog","blogTitle":"Blog"}')}}]); \ No newline at end of file diff --git a/assets/js/9e4087bc.1f4ede9b.js b/assets/js/9e4087bc.1f4ede9b.js deleted file mode 100644 index 53a6f9e1d..000000000 --- a/assets/js/9e4087bc.1f4ede9b.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[2711],{9331:(e,s,r)=>{r.r(s),r.d(s,{default:()=>o});r(6540);var t=r(5489),a=r(1312),i=r(9024),n=r(8511),c=r(1107),l=r(4848);function h(e){let{year:s,posts:r}=e;return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(c.A,{as:"h3",id:s,children:s}),(0,l.jsx)("ul",{children:r.map((e=>(0,l.jsx)("li",{children:(0,l.jsxs)(t.A,{to:e.metadata.permalink,children:[e.metadata.formattedDate," - ",e.metadata.title]})},e.metadata.date)))})]})}function d(e){let{years:s}=e;return(0,l.jsx)("section",{className:"margin-vert--lg",children:(0,l.jsx)("div",{className:"container",children:(0,l.jsx)("div",{className:"row",children:s.map(((e,s)=>(0,l.jsx)("div",{className:"col col--4 margin-vert--lg",children:(0,l.jsx)(h,{...e})},s)))})})})}function o(e){let{archive:s}=e;const r=(0,a.T)({id:"theme.blog.archive.title",message:"Archive",description:"The page & hero title of the blog archive page"}),t=(0,a.T)({id:"theme.blog.archive.description",message:"Archive",description:"The page & hero description of the blog archive page"}),h=function(e){const s=e.reduce(((e,s)=>{const r=s.metadata.date.split("-")[0],t=e.get(r)??[];return e.set(r,[s,...t])}),new Map);return Array.from(s,(e=>{let[s,r]=e;return{year:s,posts:r}}))}(s.blogPosts);return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(i.be,{title:r,description:t}),(0,l.jsxs)(n.A,{children:[(0,l.jsx)("header",{className:"hero hero--primary",children:(0,l.jsxs)("div",{className:"container",children:[(0,l.jsx)(c.A,{as:"h1",className:"hero__title",children:r}),(0,l.jsx)("p",{className:"hero__subtitle",children:t})]})}),(0,l.jsx)("main",{children:h.length>0&&(0,l.jsx)(d,{years:h})})]})]})}}}]); \ No newline at end of file diff --git a/assets/js/9f1290f8.547349cf.js b/assets/js/9f1290f8.547349cf.js deleted file mode 100644 index e67812b0b..000000000 --- a/assets/js/9f1290f8.547349cf.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[6102],{841:(e,n,i)=>{i.r(n),i.d(n,{assets:()=>c,contentTitle:()=>s,default:()=>a,frontMatter:()=>l,metadata:()=>t,toc:()=>h});var r=i(4848),d=i(8453);const l={id:"DiscordEmitterPlugin",title:"Interface: DiscordEmitterPlugin",sidebar_label:"DiscordEmitterPlugin",sidebar_position:0,custom_edit_url:null},s=void 0,t={id:"api/interfaces/DiscordEmitterPlugin",title:"Interface: DiscordEmitterPlugin",description:"Hierarchy",source:"@site/docs/api/interfaces/DiscordEmitterPlugin.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/DiscordEmitterPlugin",permalink:"/docs/api/interfaces/DiscordEmitterPlugin",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"DiscordEmitterPlugin",title:"Interface: DiscordEmitterPlugin",sidebar_label:"DiscordEmitterPlugin",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"DependencyConfiguration",permalink:"/docs/api/interfaces/DependencyConfiguration"},next:{title:"DiscordEventCommand",permalink:"/docs/api/interfaces/DiscordEventCommand"}},c={},h=[{value:"Hierarchy",id:"hierarchy",level:2},{value:"Properties",id:"properties",level:2},{value:"description",id:"description",level:3},{value:"Inherited from",id:"inherited-from",level:4},{value:"Defined in",id:"defined-in",level:4},{value:"execute",id:"execute",level:3},{value:"Type declaration",id:"type-declaration",level:4},{value:"Parameters",id:"parameters",level:5},{value:"Returns",id:"returns",level:5},{value:"Defined in",id:"defined-in-1",level:4},{value:"name",id:"name",level:3},{value:"Inherited from",id:"inherited-from-1",level:4},{value:"Defined in",id:"defined-in-2",level:4},{value:"type",id:"type",level:3},{value:"Overrides",id:"overrides",level:4},{value:"Defined in",id:"defined-in-3",level:4}];function o(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",h5:"h5",hr:"hr",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,d.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(n.h2,{id:"hierarchy",children:"Hierarchy"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:(0,r.jsx)(n.code,{children:"Plugin"})})}),"\n",(0,r.jsxs)(n.p,{children:["\u21b3 ",(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"DiscordEmitterPlugin"})})]}),"\n"]}),"\n"]}),"\n",(0,r.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,r.jsx)(n.h3,{id:"description",children:"description"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"description"}),": ",(0,r.jsx)(n.code,{children:"string"})]}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Deprecated"})})}),"\n",(0,r.jsx)(n.p,{children:"will be removed in the next update"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from",children:"Inherited from"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:"Plugin"}),".",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin#description",children:"description"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L33",children:"src/handler/plugins/plugin.ts:33"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"execute",children:"execute"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"execute"}),": (",(0,r.jsx)(n.code,{children:"payload"}),": { ",(0,r.jsx)(n.code,{children:"absPath"}),": ",(0,r.jsx)(n.code,{children:"string"})," ; ",(0,r.jsx)(n.code,{children:"mod"}),": ",(0,r.jsx)(n.code,{children:"DiscordEventCommand"})," & { ",(0,r.jsx)(n.code,{children:"name"}),": ",(0,r.jsx)(n.code,{children:"string"})," } }, ",(0,r.jsx)(n.code,{children:"controller"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Controller",children:(0,r.jsx)(n.code,{children:"Controller"})}),") => ",(0,r.jsx)(n.code,{children:"Awaitable"}),"<",(0,r.jsx)(n.code,{children:"Result"}),"<",(0,r.jsx)(n.code,{children:"void"}),", ",(0,r.jsx)(n.code,{children:"void"}),">>"]}),"\n",(0,r.jsx)(n.h4,{id:"type-declaration",children:"Type declaration"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 (",(0,r.jsx)(n.code,{children:"payload"}),", ",(0,r.jsx)(n.code,{children:"controller"}),"): ",(0,r.jsx)(n.code,{children:"Awaitable"}),"<",(0,r.jsx)(n.code,{children:"Result"}),"<",(0,r.jsx)(n.code,{children:"void"}),", ",(0,r.jsx)(n.code,{children:"void"}),">>"]}),"\n",(0,r.jsx)(n.h5,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"payload"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"Object"})})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"payload.absPath"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"string"})})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"payload.mod"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"DiscordEventCommand"})," & { ",(0,r.jsx)(n.code,{children:"name"}),": ",(0,r.jsx)(n.code,{children:"string"})," }"]})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"controller"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Controller",children:(0,r.jsx)(n.code,{children:"Controller"})})})]})]})]}),"\n",(0,r.jsx)(n.h5,{id:"returns",children:"Returns"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.code,{children:"Awaitable"}),"<",(0,r.jsx)(n.code,{children:"Result"}),"<",(0,r.jsx)(n.code,{children:"void"}),", ",(0,r.jsx)(n.code,{children:"void"}),">>"]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L49",children:"src/handler/plugins/plugin.ts:49"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"name",children:"name"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"name"}),": ",(0,r.jsx)(n.code,{children:"string"})]}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Deprecated"})})}),"\n",(0,r.jsx)(n.p,{children:"will be removed in the next update"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-1",children:"Inherited from"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:"Plugin"}),".",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin#name",children:"name"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L31",children:"src/handler/plugins/plugin.ts:31"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"type",children:"type"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"type"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/enums/PluginType#command",children:(0,r.jsx)(n.code,{children:"Command"})})]}),"\n",(0,r.jsx)(n.h4,{id:"overrides",children:"Overrides"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:"Plugin"}),".",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin#type",children:"type"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L48",children:"src/handler/plugins/plugin.ts:48"})})]})}function a(e={}){const{wrapper:n}={...(0,d.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(o,{...e})}):o(e)}},8453:(e,n,i)=>{i.d(n,{R:()=>s,x:()=>t});var r=i(6540);const d={},l=r.createContext(d);function s(e){const n=r.useContext(l);return r.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function t(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(d):e.components||d:s(e.components),r.createElement(l.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/a0b9ee13.29ed2101.js b/assets/js/a0b9ee13.29ed2101.js deleted file mode 100644 index 3365a86de..000000000 --- a/assets/js/a0b9ee13.29ed2101.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[7557],{3045:(e,n,r)=>{r.r(n),r.d(n,{assets:()=>c,contentTitle:()=>t,default:()=>a,frontMatter:()=>s,metadata:()=>l,toc:()=>h});var i=r(4848),d=r(8453);const s={id:"SernEventCommand",title:"Interface: SernEventCommand ",sidebar_label:"SernEventCommand",sidebar_position:0,custom_edit_url:null},t=void 0,l={id:"api/interfaces/SernEventCommand",title:"Interface: SernEventCommand ",description:"Type parameters",source:"@site/docs/api/interfaces/SernEventCommand.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/SernEventCommand",permalink:"/docs/api/interfaces/SernEventCommand",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"SernEventCommand",title:"Interface: SernEventCommand ",sidebar_label:"SernEventCommand",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"SernEmitterPlugin",permalink:"/docs/api/interfaces/SernEmitterPlugin"},next:{title:"SernEventPlugin",permalink:"/docs/api/interfaces/SernEventPlugin"}},c={},h=[{value:"Type parameters",id:"type-parameters",level:2},{value:"Hierarchy",id:"hierarchy",level:2},{value:"Properties",id:"properties",level:2},{value:"description",id:"description",level:3},{value:"Inherited from",id:"inherited-from",level:4},{value:"Defined in",id:"defined-in",level:4},{value:"name",id:"name",level:3},{value:"Overrides",id:"overrides",level:4},{value:"Defined in",id:"defined-in-1",level:4},{value:"onEvent",id:"onevent",level:3},{value:"Inherited from",id:"inherited-from-1",level:4},{value:"Defined in",id:"defined-in-2",level:4},{value:"plugins",id:"plugins",level:3},{value:"Inherited from",id:"inherited-from-2",level:4},{value:"Defined in",id:"defined-in-3",level:4},{value:"type",id:"type",level:3},{value:"Overrides",id:"overrides-1",level:4},{value:"Defined in",id:"defined-in-4",level:4},{value:"Methods",id:"methods",level:2},{value:"execute",id:"execute",level:3},{value:"Parameters",id:"parameters",level:4},{value:"Returns",id:"returns",level:4},{value:"Overrides",id:"overrides-2",level:4},{value:"Defined in",id:"defined-in-5",level:4}];function o(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",hr:"hr",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,d.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(n.h2,{id:"type-parameters",children:"Type parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,i.jsxs)(n.table,{children:[(0,i.jsx)(n.thead,{children:(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,i.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,i.jsx)(n.tbody,{children:(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{style:{textAlign:"left"},children:(0,i.jsx)(n.code,{children:"T"})}),(0,i.jsxs)(n.td,{style:{textAlign:"left"},children:["extends keyof ",(0,i.jsx)(n.a,{href:"/docs/api/interfaces/SernEventsMapping",children:(0,i.jsx)(n.code,{children:"SernEventsMapping"})})," = keyof ",(0,i.jsx)(n.a,{href:"/docs/api/interfaces/SernEventsMapping",children:(0,i.jsx)(n.code,{children:"SernEventsMapping"})})]})]})})]}),"\n",(0,i.jsx)(n.h2,{id:"hierarchy",children:"Hierarchy"}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsxs)(n.li,{children:["\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.code,{children:"Module"})}),"\n",(0,i.jsxs)(n.p,{children:["\u21b3 ",(0,i.jsx)(n.strong,{children:(0,i.jsx)(n.code,{children:"SernEventCommand"})})]}),"\n"]}),"\n"]}),"\n",(0,i.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,i.jsx)(n.h3,{id:"description",children:"description"}),"\n",(0,i.jsxs)(n.p,{children:["\u2022 ",(0,i.jsx)(n.code,{children:"Optional"})," ",(0,i.jsx)(n.strong,{children:"description"}),": ",(0,i.jsx)(n.code,{children:"string"})]}),"\n",(0,i.jsx)(n.h4,{id:"inherited-from",children:"Inherited from"}),"\n",(0,i.jsx)(n.p,{children:"Module.description"}),"\n",(0,i.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L36",children:"src/types/core-modules.ts:36"})}),"\n",(0,i.jsx)(n.hr,{}),"\n",(0,i.jsx)(n.h3,{id:"name",children:"name"}),"\n",(0,i.jsxs)(n.p,{children:["\u2022 ",(0,i.jsx)(n.code,{children:"Optional"})," ",(0,i.jsx)(n.strong,{children:"name"}),": ",(0,i.jsx)(n.code,{children:"T"})]}),"\n",(0,i.jsx)(n.h4,{id:"overrides",children:"Overrides"}),"\n",(0,i.jsx)(n.p,{children:"Module.name"}),"\n",(0,i.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L42",children:"src/types/core-modules.ts:42"})}),"\n",(0,i.jsx)(n.hr,{}),"\n",(0,i.jsx)(n.h3,{id:"onevent",children:"onEvent"}),"\n",(0,i.jsxs)(n.p,{children:["\u2022 ",(0,i.jsx)(n.strong,{children:"onEvent"}),": ",(0,i.jsx)(n.a,{href:"/docs/api/interfaces/ControlPlugin",children:(0,i.jsx)(n.code,{children:"ControlPlugin"})}),"<",(0,i.jsx)(n.code,{children:"any"}),"[]>[]"]}),"\n",(0,i.jsx)(n.h4,{id:"inherited-from-1",children:"Inherited from"}),"\n",(0,i.jsx)(n.p,{children:"Module.onEvent"}),"\n",(0,i.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L34",children:"src/types/core-modules.ts:34"})}),"\n",(0,i.jsx)(n.hr,{}),"\n",(0,i.jsx)(n.h3,{id:"plugins",children:"plugins"}),"\n",(0,i.jsxs)(n.p,{children:["\u2022 ",(0,i.jsx)(n.strong,{children:"plugins"}),": ",(0,i.jsx)(n.a,{href:"/docs/api/interfaces/InitPlugin",children:(0,i.jsx)(n.code,{children:"InitPlugin"})}),"<",(0,i.jsx)(n.code,{children:"any"}),"[]>[]"]}),"\n",(0,i.jsx)(n.h4,{id:"inherited-from-2",children:"Inherited from"}),"\n",(0,i.jsx)(n.p,{children:"Module.plugins"}),"\n",(0,i.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L35",children:"src/types/core-modules.ts:35"})}),"\n",(0,i.jsx)(n.hr,{}),"\n",(0,i.jsx)(n.h3,{id:"type",children:"type"}),"\n",(0,i.jsxs)(n.p,{children:["\u2022 ",(0,i.jsx)(n.strong,{children:"type"}),": ",(0,i.jsx)(n.a,{href:"/docs/api/enums/EventType#sern",children:(0,i.jsx)(n.code,{children:"Sern"})})]}),"\n",(0,i.jsx)(n.h4,{id:"overrides-1",children:"Overrides"}),"\n",(0,i.jsx)(n.p,{children:"Module.type"}),"\n",(0,i.jsx)(n.h4,{id:"defined-in-4",children:"Defined in"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L43",children:"src/types/core-modules.ts:43"})}),"\n",(0,i.jsx)(n.h2,{id:"methods",children:"Methods"}),"\n",(0,i.jsx)(n.h3,{id:"execute",children:"execute"}),"\n",(0,i.jsxs)(n.p,{children:["\u25b8 ",(0,i.jsx)(n.strong,{children:"execute"}),"(",(0,i.jsx)(n.code,{children:"...args"}),"): ",(0,i.jsx)(n.code,{children:"unknown"})]}),"\n",(0,i.jsx)(n.h4,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,i.jsxs)(n.table,{children:[(0,i.jsx)(n.thead,{children:(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,i.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,i.jsx)(n.tbody,{children:(0,i.jsxs)(n.tr,{children:[(0,i.jsx)(n.td,{style:{textAlign:"left"},children:(0,i.jsx)(n.code,{children:"...args"})}),(0,i.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,i.jsx)(n.a,{href:"/docs/api/interfaces/SernEventsMapping",children:(0,i.jsx)(n.code,{children:"SernEventsMapping"})}),"[",(0,i.jsx)(n.code,{children:"T"}),"]"]})]})})]}),"\n",(0,i.jsx)(n.h4,{id:"returns",children:"Returns"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.code,{children:"unknown"})}),"\n",(0,i.jsx)(n.h4,{id:"overrides-2",children:"Overrides"}),"\n",(0,i.jsx)(n.p,{children:"Module.execute"}),"\n",(0,i.jsx)(n.h4,{id:"defined-in-5",children:"Defined in"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L44",children:"src/types/core-modules.ts:44"})})]})}function a(e={}){const{wrapper:n}={...(0,d.R)(),...e.components};return n?(0,i.jsx)(n,{...e,children:(0,i.jsx)(o,{...e})}):o(e)}},8453:(e,n,r)=>{r.d(n,{R:()=>t,x:()=>l});var i=r(6540);const d={},s=i.createContext(d);function t(e){const n=i.useContext(s);return i.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function l(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(d):e.components||d:t(e.components),i.createElement(s.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/a0fd2c7a.408ca2fb.js b/assets/js/a0fd2c7a.408ca2fb.js deleted file mode 100644 index 00749ca6f..000000000 --- a/assets/js/a0fd2c7a.408ca2fb.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[7767],{8787:(e,n,i)=>{i.r(n),i.d(n,{assets:()=>c,contentTitle:()=>l,default:()=>a,frontMatter:()=>s,metadata:()=>t,toc:()=>o});var d=i(4848),r=i(8453);const s={id:"DiscordEventCommand",title:"Interface: DiscordEventCommand ",sidebar_label:"DiscordEventCommand",sidebar_position:0,custom_edit_url:null},l=void 0,t={id:"api/interfaces/DiscordEventCommand",title:"Interface: DiscordEventCommand ",description:"Type parameters",source:"@site/docs/api/interfaces/DiscordEventCommand.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/DiscordEventCommand",permalink:"/docs/api/interfaces/DiscordEventCommand",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"DiscordEventCommand",title:"Interface: DiscordEventCommand ",sidebar_label:"DiscordEventCommand",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"DiscordEmitterPlugin",permalink:"/docs/api/interfaces/DiscordEmitterPlugin"},next:{title:"DiscordEventPlugin",permalink:"/docs/api/interfaces/DiscordEventPlugin"}},c={},o=[{value:"Type parameters",id:"type-parameters",level:2},{value:"Hierarchy",id:"hierarchy",level:2},{value:"Properties",id:"properties",level:2},{value:"description",id:"description",level:3},{value:"Inherited from",id:"inherited-from",level:4},{value:"Defined in",id:"defined-in",level:4},{value:"name",id:"name",level:3},{value:"Overrides",id:"overrides",level:4},{value:"Defined in",id:"defined-in-1",level:4},{value:"onEvent",id:"onevent",level:3},{value:"Inherited from",id:"inherited-from-1",level:4},{value:"Defined in",id:"defined-in-2",level:4},{value:"plugins",id:"plugins",level:3},{value:"Inherited from",id:"inherited-from-2",level:4},{value:"Defined in",id:"defined-in-3",level:4},{value:"type",id:"type",level:3},{value:"Overrides",id:"overrides-1",level:4},{value:"Defined in",id:"defined-in-4",level:4},{value:"Methods",id:"methods",level:2},{value:"execute",id:"execute",level:3},{value:"Parameters",id:"parameters",level:4},{value:"Returns",id:"returns",level:4},{value:"Overrides",id:"overrides-2",level:4},{value:"Defined in",id:"defined-in-5",level:4}];function h(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",hr:"hr",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,r.R)(),...e.components};return(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(n.h2,{id:"type-parameters",children:"Type parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,d.jsxs)(n.table,{children:[(0,d.jsx)(n.thead,{children:(0,d.jsxs)(n.tr,{children:[(0,d.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,d.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,d.jsx)(n.tbody,{children:(0,d.jsxs)(n.tr,{children:[(0,d.jsx)(n.td,{style:{textAlign:"left"},children:(0,d.jsx)(n.code,{children:"T"})}),(0,d.jsxs)(n.td,{style:{textAlign:"left"},children:["extends keyof ",(0,d.jsx)(n.code,{children:"ClientEvents"})," = keyof ",(0,d.jsx)(n.code,{children:"ClientEvents"})]})]})})]}),"\n",(0,d.jsx)(n.h2,{id:"hierarchy",children:"Hierarchy"}),"\n",(0,d.jsxs)(n.ul,{children:["\n",(0,d.jsxs)(n.li,{children:["\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.code,{children:"Module"})}),"\n",(0,d.jsxs)(n.p,{children:["\u21b3 ",(0,d.jsx)(n.strong,{children:(0,d.jsx)(n.code,{children:"DiscordEventCommand"})})]}),"\n"]}),"\n"]}),"\n",(0,d.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,d.jsx)(n.h3,{id:"description",children:"description"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.code,{children:"Optional"})," ",(0,d.jsx)(n.strong,{children:"description"}),": ",(0,d.jsx)(n.code,{children:"string"})]}),"\n",(0,d.jsx)(n.h4,{id:"inherited-from",children:"Inherited from"}),"\n",(0,d.jsx)(n.p,{children:"Module.description"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L36",children:"src/types/core-modules.ts:36"})}),"\n",(0,d.jsx)(n.hr,{}),"\n",(0,d.jsx)(n.h3,{id:"name",children:"name"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.code,{children:"Optional"})," ",(0,d.jsx)(n.strong,{children:"name"}),": ",(0,d.jsx)(n.code,{children:"T"})]}),"\n",(0,d.jsx)(n.h4,{id:"overrides",children:"Overrides"}),"\n",(0,d.jsx)(n.p,{children:"Module.name"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L106",children:"src/types/core-modules.ts:106"})}),"\n",(0,d.jsx)(n.hr,{}),"\n",(0,d.jsx)(n.h3,{id:"onevent",children:"onEvent"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.strong,{children:"onEvent"}),": ",(0,d.jsx)(n.a,{href:"/docs/api/interfaces/ControlPlugin",children:(0,d.jsx)(n.code,{children:"ControlPlugin"})}),"<",(0,d.jsx)(n.code,{children:"any"}),"[]>[]"]}),"\n",(0,d.jsx)(n.h4,{id:"inherited-from-1",children:"Inherited from"}),"\n",(0,d.jsx)(n.p,{children:"Module.onEvent"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L34",children:"src/types/core-modules.ts:34"})}),"\n",(0,d.jsx)(n.hr,{}),"\n",(0,d.jsx)(n.h3,{id:"plugins",children:"plugins"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.strong,{children:"plugins"}),": ",(0,d.jsx)(n.a,{href:"/docs/api/interfaces/InitPlugin",children:(0,d.jsx)(n.code,{children:"InitPlugin"})}),"<",(0,d.jsx)(n.code,{children:"any"}),"[]>[]"]}),"\n",(0,d.jsx)(n.h4,{id:"inherited-from-2",children:"Inherited from"}),"\n",(0,d.jsx)(n.p,{children:"Module.plugins"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L35",children:"src/types/core-modules.ts:35"})}),"\n",(0,d.jsx)(n.hr,{}),"\n",(0,d.jsx)(n.h3,{id:"type",children:"type"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.strong,{children:"type"}),": ",(0,d.jsx)(n.a,{href:"/docs/api/enums/EventType#discord",children:(0,d.jsx)(n.code,{children:"Discord"})})]}),"\n",(0,d.jsx)(n.h4,{id:"overrides-1",children:"Overrides"}),"\n",(0,d.jsx)(n.p,{children:"Module.type"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in-4",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L107",children:"src/types/core-modules.ts:107"})}),"\n",(0,d.jsx)(n.h2,{id:"methods",children:"Methods"}),"\n",(0,d.jsx)(n.h3,{id:"execute",children:"execute"}),"\n",(0,d.jsxs)(n.p,{children:["\u25b8 ",(0,d.jsx)(n.strong,{children:"execute"}),"(",(0,d.jsx)(n.code,{children:"...args"}),"): ",(0,d.jsx)(n.code,{children:"unknown"})]}),"\n",(0,d.jsx)(n.h4,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,d.jsxs)(n.table,{children:[(0,d.jsx)(n.thead,{children:(0,d.jsxs)(n.tr,{children:[(0,d.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,d.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,d.jsx)(n.tbody,{children:(0,d.jsxs)(n.tr,{children:[(0,d.jsx)(n.td,{style:{textAlign:"left"},children:(0,d.jsx)(n.code,{children:"...args"})}),(0,d.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,d.jsx)(n.code,{children:"ClientEvents"}),"[",(0,d.jsx)(n.code,{children:"T"}),"]"]})]})})]}),"\n",(0,d.jsx)(n.h4,{id:"returns",children:"Returns"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.code,{children:"unknown"})}),"\n",(0,d.jsx)(n.h4,{id:"overrides-2",children:"Overrides"}),"\n",(0,d.jsx)(n.p,{children:"Module.execute"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in-5",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L108",children:"src/types/core-modules.ts:108"})})]})}function a(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,d.jsx)(n,{...e,children:(0,d.jsx)(h,{...e})}):h(e)}},8453:(e,n,i)=>{i.d(n,{R:()=>l,x:()=>t});var d=i(6540);const r={},s=d.createContext(r);function l(e){const n=d.useContext(s);return d.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function t(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(r):e.components||r:l(e.components),d.createElement(s.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/a3030d1c.2ebc2980.js b/assets/js/a3030d1c.2ebc2980.js deleted file mode 100644 index 26b6eedcc..000000000 --- a/assets/js/a3030d1c.2ebc2980.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[5776],{577:(e,n,d)=>{d.r(n),d.d(n,{assets:()=>c,contentTitle:()=>s,default:()=>o,frontMatter:()=>t,metadata:()=>i,toc:()=>a});var l=d(4848),r=d(8453);const t={id:"ModuleManager",title:"Interface: ModuleManager",sidebar_label:"ModuleManager",sidebar_position:0,custom_edit_url:null},s=void 0,i={id:"api/interfaces/ModuleManager",title:"Interface: ModuleManager",description:"Since",source:"@site/docs/api/interfaces/ModuleManager.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/ModuleManager",permalink:"/docs/api/interfaces/ModuleManager",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"ModuleManager",title:"Interface: ModuleManager",sidebar_label:"ModuleManager",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"Module",permalink:"/docs/api/interfaces/Module"},next:{title:"Plugin",permalink:"/docs/api/interfaces/Plugin"}},c={},a=[{value:"Hierarchy",id:"hierarchy",level:2},{value:"Implemented by",id:"implemented-by",level:2},{value:"Methods",id:"methods",level:2},{value:"get",id:"get",level:3},{value:"Parameters",id:"parameters",level:4},{value:"Returns",id:"returns",level:4},{value:"Defined in",id:"defined-in",level:4},{value:"getByNameCommandType",id:"getbynamecommandtype",level:3},{value:"Type parameters",id:"type-parameters",level:4},{value:"Parameters",id:"parameters-1",level:4},{value:"Returns",id:"returns-1",level:4},{value:"Defined in",id:"defined-in-1",level:4},{value:"getMetadata",id:"getmetadata",level:3},{value:"Parameters",id:"parameters-2",level:4},{value:"Returns",id:"returns-2",level:4},{value:"Inherited from",id:"inherited-from",level:4},{value:"Defined in",id:"defined-in-2",level:4},{value:"getPublishableCommands",id:"getpublishablecommands",level:3},{value:"Returns",id:"returns-3",level:4},{value:"Defined in",id:"defined-in-3",level:4},{value:"set",id:"set",level:3},{value:"Parameters",id:"parameters-3",level:4},{value:"Returns",id:"returns-4",level:4},{value:"Defined in",id:"defined-in-4",level:4},{value:"setMetadata",id:"setmetadata",level:3},{value:"Parameters",id:"parameters-4",level:4},{value:"Returns",id:"returns-5",level:4},{value:"Inherited from",id:"inherited-from-1",level:4},{value:"Defined in",id:"defined-in-5",level:4}];function h(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",hr:"hr",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,r.R)(),...e.components};return(0,l.jsxs)(l.Fragment,{children:[(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:(0,l.jsx)(n.code,{children:"Since"})})}),"\n",(0,l.jsx)(n.p,{children:"2.0.0"}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:"direct access to the module manager will be removed in version 4"}),"\n"]}),"\n",(0,l.jsx)(n.h2,{id:"hierarchy",children:"Hierarchy"}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsxs)(n.li,{children:["\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.code,{children:"MetadataAccess"})}),"\n",(0,l.jsxs)(n.p,{children:["\u21b3 ",(0,l.jsx)(n.strong,{children:(0,l.jsx)(n.code,{children:"ModuleManager"})})]}),"\n"]}),"\n"]}),"\n",(0,l.jsx)(n.h2,{id:"implemented-by",children:"Implemented by"}),"\n",(0,l.jsxs)(n.ul,{children:["\n",(0,l.jsx)(n.li,{children:(0,l.jsx)(n.a,{href:"/docs/api/classes/DefaultModuleManager",children:(0,l.jsx)(n.code,{children:"DefaultModuleManager"})})}),"\n"]}),"\n",(0,l.jsx)(n.h2,{id:"methods",children:"Methods"}),"\n",(0,l.jsx)(n.h3,{id:"get",children:"get"}),"\n",(0,l.jsxs)(n.p,{children:["\u25b8 ",(0,l.jsx)(n.strong,{children:"get"}),"(",(0,l.jsx)(n.code,{children:"id"}),"): ",(0,l.jsx)(n.code,{children:"undefined"})," | ",(0,l.jsx)(n.code,{children:"Module"})]}),"\n",(0,l.jsx)(n.h4,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,l.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,l.jsx)(n.tbody,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"id"})}),(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"string"})})]})})]}),"\n",(0,l.jsx)(n.h4,{id:"returns",children:"Returns"}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.code,{children:"undefined"})," | ",(0,l.jsx)(n.code,{children:"Module"})]}),"\n",(0,l.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/contracts/module-manager.ts#L19",children:"src/core/contracts/module-manager.ts:19"})}),"\n",(0,l.jsx)(n.hr,{}),"\n",(0,l.jsx)(n.h3,{id:"getbynamecommandtype",children:"getByNameCommandType"}),"\n",(0,l.jsxs)(n.p,{children:["\u25b8 ",(0,l.jsx)(n.strong,{children:"getByNameCommandType"}),"<",(0,l.jsx)(n.code,{children:"T"}),">(",(0,l.jsx)(n.code,{children:"name"}),", ",(0,l.jsx)(n.code,{children:"commandType"}),"): ",(0,l.jsx)(n.code,{children:"undefined"})," | ",(0,l.jsx)(n.a,{href:"/docs/api/interfaces/CommandModuleDefs",children:(0,l.jsx)(n.code,{children:"CommandModuleDefs"})}),"[",(0,l.jsx)(n.code,{children:"T"}),"]"]}),"\n",(0,l.jsx)(n.h4,{id:"type-parameters",children:"Type parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,l.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,l.jsx)(n.tbody,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"T"})}),(0,l.jsxs)(n.td,{style:{textAlign:"left"},children:["extends ",(0,l.jsx)(n.a,{href:"/docs/api/enums/CommandType",children:(0,l.jsx)(n.code,{children:"CommandType"})})]})]})})]}),"\n",(0,l.jsx)(n.h4,{id:"parameters-1",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,l.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,l.jsxs)(n.tbody,{children:[(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"name"})}),(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"string"})})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"commandType"})}),(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"T"})})]})]})]}),"\n",(0,l.jsx)(n.h4,{id:"returns-1",children:"Returns"}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.code,{children:"undefined"})," | ",(0,l.jsx)(n.a,{href:"/docs/api/interfaces/CommandModuleDefs",children:(0,l.jsx)(n.code,{children:"CommandModuleDefs"})}),"[",(0,l.jsx)(n.code,{children:"T"}),"]"]}),"\n",(0,l.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/contracts/module-manager.ts#L30",children:"src/core/contracts/module-manager.ts:30"})}),"\n",(0,l.jsx)(n.hr,{}),"\n",(0,l.jsx)(n.h3,{id:"getmetadata",children:"getMetadata"}),"\n",(0,l.jsxs)(n.p,{children:["\u25b8 ",(0,l.jsx)(n.strong,{children:"getMetadata"}),"(",(0,l.jsx)(n.code,{children:"m"}),"): ",(0,l.jsx)(n.code,{children:"undefined"})," | ",(0,l.jsx)(n.code,{children:"CommandMeta"})]}),"\n",(0,l.jsx)(n.h4,{id:"parameters-2",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,l.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,l.jsx)(n.tbody,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"m"})}),(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"Module"})})]})})]}),"\n",(0,l.jsx)(n.h4,{id:"returns-2",children:"Returns"}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.code,{children:"undefined"})," | ",(0,l.jsx)(n.code,{children:"CommandMeta"})]}),"\n",(0,l.jsx)(n.h4,{id:"inherited-from",children:"Inherited from"}),"\n",(0,l.jsx)(n.p,{children:"MetadataAccess.getMetadata"}),"\n",(0,l.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/contracts/module-manager.ts#L10",children:"src/core/contracts/module-manager.ts:10"})}),"\n",(0,l.jsx)(n.hr,{}),"\n",(0,l.jsx)(n.h3,{id:"getpublishablecommands",children:"getPublishableCommands"}),"\n",(0,l.jsxs)(n.p,{children:["\u25b8 ",(0,l.jsx)(n.strong,{children:"getPublishableCommands"}),"(): ",(0,l.jsx)(n.a,{href:"/docs/api/modules#commandmodule",children:(0,l.jsx)(n.code,{children:"CommandModule"})}),"[]"]}),"\n",(0,l.jsx)(n.h4,{id:"returns-3",children:"Returns"}),"\n",(0,l.jsxs)(n.p,{children:[(0,l.jsx)(n.a,{href:"/docs/api/modules#commandmodule",children:(0,l.jsx)(n.code,{children:"CommandModule"})}),"[]"]}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.strong,{children:(0,l.jsx)(n.code,{children:"Deprecated"})})}),"\n",(0,l.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/contracts/module-manager.ts#L25",children:"src/core/contracts/module-manager.ts:25"})}),"\n",(0,l.jsx)(n.hr,{}),"\n",(0,l.jsx)(n.h3,{id:"set",children:"set"}),"\n",(0,l.jsxs)(n.p,{children:["\u25b8 ",(0,l.jsx)(n.strong,{children:"set"}),"(",(0,l.jsx)(n.code,{children:"id"}),", ",(0,l.jsx)(n.code,{children:"path"}),"): ",(0,l.jsx)(n.code,{children:"void"})]}),"\n",(0,l.jsx)(n.h4,{id:"parameters-3",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,l.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,l.jsxs)(n.tbody,{children:[(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"id"})}),(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"string"})})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"path"})}),(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"Module"})})]})]})]}),"\n",(0,l.jsx)(n.h4,{id:"returns-4",children:"Returns"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.code,{children:"void"})}),"\n",(0,l.jsx)(n.h4,{id:"defined-in-4",children:"Defined in"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/contracts/module-manager.ts#L21",children:"src/core/contracts/module-manager.ts:21"})}),"\n",(0,l.jsx)(n.hr,{}),"\n",(0,l.jsx)(n.h3,{id:"setmetadata",children:"setMetadata"}),"\n",(0,l.jsxs)(n.p,{children:["\u25b8 ",(0,l.jsx)(n.strong,{children:"setMetadata"}),"(",(0,l.jsx)(n.code,{children:"m"}),", ",(0,l.jsx)(n.code,{children:"c"}),"): ",(0,l.jsx)(n.code,{children:"void"})]}),"\n",(0,l.jsx)(n.h4,{id:"parameters-4",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,l.jsxs)(n.table,{children:[(0,l.jsx)(n.thead,{children:(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,l.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,l.jsxs)(n.tbody,{children:[(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"m"})}),(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"Module"})})]}),(0,l.jsxs)(n.tr,{children:[(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"c"})}),(0,l.jsx)(n.td,{style:{textAlign:"left"},children:(0,l.jsx)(n.code,{children:"CommandMeta"})})]})]})]}),"\n",(0,l.jsx)(n.h4,{id:"returns-5",children:"Returns"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.code,{children:"void"})}),"\n",(0,l.jsx)(n.h4,{id:"inherited-from-1",children:"Inherited from"}),"\n",(0,l.jsx)(n.p,{children:"MetadataAccess.setMetadata"}),"\n",(0,l.jsx)(n.h4,{id:"defined-in-5",children:"Defined in"}),"\n",(0,l.jsx)(n.p,{children:(0,l.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/contracts/module-manager.ts#L11",children:"src/core/contracts/module-manager.ts:11"})})]})}function o(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,l.jsx)(n,{...e,children:(0,l.jsx)(h,{...e})}):h(e)}},8453:(e,n,d)=>{d.d(n,{R:()=>s,x:()=>i});var l=d(6540);const r={},t=l.createContext(r);function s(e){const n=l.useContext(t);return l.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function i(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(r):e.components||r:s(e.components),l.createElement(t.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/a4d0ee3e.3528b007.js b/assets/js/a4d0ee3e.3528b007.js deleted file mode 100644 index 133dc0e2c..000000000 --- a/assets/js/a4d0ee3e.3528b007.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[2014],{6091:(e,n,i)=>{i.r(n),i.d(n,{assets:()=>c,contentTitle:()=>t,default:()=>a,frontMatter:()=>l,metadata:()=>s,toc:()=>o});var d=i(4848),r=i(8453);const l={id:"MentionableSelectCommand",title:"Interface: MentionableSelectCommand",sidebar_label:"MentionableSelectCommand",sidebar_position:0,custom_edit_url:null},t=void 0,s={id:"api/interfaces/MentionableSelectCommand",title:"Interface: MentionableSelectCommand",description:"Hierarchy",source:"@site/docs/api/interfaces/MentionableSelectCommand.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/MentionableSelectCommand",permalink:"/docs/api/interfaces/MentionableSelectCommand",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"MentionableSelectCommand",title:"Interface: MentionableSelectCommand",sidebar_label:"MentionableSelectCommand",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"Logging",permalink:"/docs/api/interfaces/Logging"},next:{title:"ModalSubmitCommand",permalink:"/docs/api/interfaces/ModalSubmitCommand"}},c={},o=[{value:"Hierarchy",id:"hierarchy",level:2},{value:"Properties",id:"properties",level:2},{value:"description",id:"description",level:3},{value:"Inherited from",id:"inherited-from",level:4},{value:"Defined in",id:"defined-in",level:4},{value:"execute",id:"execute",level:3},{value:"Type declaration",id:"type-declaration",level:4},{value:"Parameters",id:"parameters",level:5},{value:"Returns",id:"returns",level:5},{value:"Overrides",id:"overrides",level:4},{value:"Defined in",id:"defined-in-1",level:4},{value:"name",id:"name",level:3},{value:"Inherited from",id:"inherited-from-1",level:4},{value:"Defined in",id:"defined-in-2",level:4},{value:"onEvent",id:"onevent",level:3},{value:"Inherited from",id:"inherited-from-2",level:4},{value:"Defined in",id:"defined-in-3",level:4},{value:"plugins",id:"plugins",level:3},{value:"Inherited from",id:"inherited-from-3",level:4},{value:"Defined in",id:"defined-in-4",level:4},{value:"type",id:"type",level:3},{value:"Overrides",id:"overrides-1",level:4},{value:"Defined in",id:"defined-in-5",level:4}];function h(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",h5:"h5",hr:"hr",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,r.R)(),...e.components};return(0,d.jsxs)(d.Fragment,{children:[(0,d.jsx)(n.h2,{id:"hierarchy",children:"Hierarchy"}),"\n",(0,d.jsxs)(n.ul,{children:["\n",(0,d.jsxs)(n.li,{children:["\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.code,{children:"Module"})}),"\n",(0,d.jsxs)(n.p,{children:["\u21b3 ",(0,d.jsx)(n.strong,{children:(0,d.jsx)(n.code,{children:"MentionableSelectCommand"})})]}),"\n"]}),"\n"]}),"\n",(0,d.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,d.jsx)(n.h3,{id:"description",children:"description"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.code,{children:"Optional"})," ",(0,d.jsx)(n.strong,{children:"description"}),": ",(0,d.jsx)(n.code,{children:"string"})]}),"\n",(0,d.jsx)(n.h4,{id:"inherited-from",children:"Inherited from"}),"\n",(0,d.jsx)(n.p,{children:"Module.description"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L36",children:"src/types/core-modules.ts:36"})}),"\n",(0,d.jsx)(n.hr,{}),"\n",(0,d.jsx)(n.h3,{id:"execute",children:"execute"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.strong,{children:"execute"}),": (",(0,d.jsx)(n.code,{children:"ctx"}),": ",(0,d.jsx)(n.code,{children:"MentionableSelectMenuInteraction"}),"<",(0,d.jsx)(n.code,{children:"CacheType"}),">) => ",(0,d.jsx)(n.code,{children:"unknown"})]}),"\n",(0,d.jsx)(n.h4,{id:"type-declaration",children:"Type declaration"}),"\n",(0,d.jsxs)(n.p,{children:["\u25b8 (",(0,d.jsx)(n.code,{children:"ctx"}),"): ",(0,d.jsx)(n.code,{children:"unknown"})]}),"\n",(0,d.jsx)(n.h5,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,d.jsxs)(n.table,{children:[(0,d.jsx)(n.thead,{children:(0,d.jsxs)(n.tr,{children:[(0,d.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,d.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,d.jsx)(n.tbody,{children:(0,d.jsxs)(n.tr,{children:[(0,d.jsx)(n.td,{style:{textAlign:"left"},children:(0,d.jsx)(n.code,{children:"ctx"})}),(0,d.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,d.jsx)(n.code,{children:"MentionableSelectMenuInteraction"}),"<",(0,d.jsx)(n.code,{children:"CacheType"}),">"]})]})})]}),"\n",(0,d.jsx)(n.h5,{id:"returns",children:"Returns"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.code,{children:"unknown"})}),"\n",(0,d.jsx)(n.h4,{id:"overrides",children:"Overrides"}),"\n",(0,d.jsx)(n.p,{children:"Module.execute"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L85",children:"src/types/core-modules.ts:85"})}),"\n",(0,d.jsx)(n.hr,{}),"\n",(0,d.jsx)(n.h3,{id:"name",children:"name"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.code,{children:"Optional"})," ",(0,d.jsx)(n.strong,{children:"name"}),": ",(0,d.jsx)(n.code,{children:"string"})]}),"\n",(0,d.jsx)(n.h4,{id:"inherited-from-1",children:"Inherited from"}),"\n",(0,d.jsx)(n.p,{children:"Module.name"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L33",children:"src/types/core-modules.ts:33"})}),"\n",(0,d.jsx)(n.hr,{}),"\n",(0,d.jsx)(n.h3,{id:"onevent",children:"onEvent"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.strong,{children:"onEvent"}),": ",(0,d.jsx)(n.a,{href:"/docs/api/interfaces/ControlPlugin",children:(0,d.jsx)(n.code,{children:"ControlPlugin"})}),"<",(0,d.jsx)(n.code,{children:"any"}),"[]>[]"]}),"\n",(0,d.jsx)(n.h4,{id:"inherited-from-2",children:"Inherited from"}),"\n",(0,d.jsx)(n.p,{children:"Module.onEvent"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L34",children:"src/types/core-modules.ts:34"})}),"\n",(0,d.jsx)(n.hr,{}),"\n",(0,d.jsx)(n.h3,{id:"plugins",children:"plugins"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.strong,{children:"plugins"}),": ",(0,d.jsx)(n.a,{href:"/docs/api/interfaces/InitPlugin",children:(0,d.jsx)(n.code,{children:"InitPlugin"})}),"<",(0,d.jsx)(n.code,{children:"any"}),"[]>[]"]}),"\n",(0,d.jsx)(n.h4,{id:"inherited-from-3",children:"Inherited from"}),"\n",(0,d.jsx)(n.p,{children:"Module.plugins"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in-4",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L35",children:"src/types/core-modules.ts:35"})}),"\n",(0,d.jsx)(n.hr,{}),"\n",(0,d.jsx)(n.h3,{id:"type",children:"type"}),"\n",(0,d.jsxs)(n.p,{children:["\u2022 ",(0,d.jsx)(n.strong,{children:"type"}),": ",(0,d.jsx)(n.a,{href:"/docs/api/enums/CommandType#mentionableselect",children:(0,d.jsx)(n.code,{children:"MentionableSelect"})})]}),"\n",(0,d.jsx)(n.h4,{id:"overrides-1",children:"Overrides"}),"\n",(0,d.jsx)(n.p,{children:"Module.type"}),"\n",(0,d.jsx)(n.h4,{id:"defined-in-5",children:"Defined in"}),"\n",(0,d.jsx)(n.p,{children:(0,d.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/core-modules.ts#L84",children:"src/types/core-modules.ts:84"})})]})}function a(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,d.jsx)(n,{...e,children:(0,d.jsx)(h,{...e})}):h(e)}},8453:(e,n,i)=>{i.d(n,{R:()=>t,x:()=>s});var d=i(6540);const r={},l=d.createContext(r);function t(e){const n=d.useContext(l);return d.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function s(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(r):e.components||r:t(e.components),d.createElement(l.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/a5467962.7db8ad68.js b/assets/js/a5467962.7db8ad68.js deleted file mode 100644 index 758ed1fae..000000000 --- a/assets/js/a5467962.7db8ad68.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[2831],{4113:(e,n,s)=>{s.r(n),s.d(n,{assets:()=>t,contentTitle:()=>l,default:()=>o,frontMatter:()=>d,metadata:()=>c,toc:()=>h});var r=s(4848),i=s(8453);const d={id:"CommandType",title:"Enumeration: CommandType",sidebar_label:"CommandType",sidebar_position:0,custom_edit_url:null},l=void 0,c={id:"api/enums/CommandType",title:"Enumeration: CommandType",description:"Since",source:"@site/docs/api/enums/CommandType.md",sourceDirName:"api/enums",slug:"/api/enums/CommandType",permalink:"/docs/api/enums/CommandType",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"CommandType",title:"Enumeration: CommandType",sidebar_label:"CommandType",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"Sern",permalink:"/docs/api/namespaces/Sern"},next:{title:"EventType",permalink:"/docs/api/enums/EventType"}},t={},h=[{value:"Enumeration Members",id:"enumeration-members",level:2},{value:"Both",id:"both",level:3},{value:"Defined in",id:"defined-in",level:4},{value:"Button",id:"button",level:3},{value:"Defined in",id:"defined-in-1",level:4},{value:"ChannelSelect",id:"channelselect",level:3},{value:"Defined in",id:"defined-in-2",level:4},{value:"CtxMsg",id:"ctxmsg",level:3},{value:"Defined in",id:"defined-in-3",level:4},{value:"CtxUser",id:"ctxuser",level:3},{value:"Defined in",id:"defined-in-4",level:4},{value:"MentionableSelect",id:"mentionableselect",level:3},{value:"Defined in",id:"defined-in-5",level:4},{value:"Modal",id:"modal",level:3},{value:"Defined in",id:"defined-in-6",level:4},{value:"RoleSelect",id:"roleselect",level:3},{value:"Defined in",id:"defined-in-7",level:4},{value:"Slash",id:"slash",level:3},{value:"Defined in",id:"defined-in-8",level:4},{value:"StringSelect",id:"stringselect",level:3},{value:"Defined in",id:"defined-in-9",level:4},{value:"Text",id:"text",level:3},{value:"Defined in",id:"defined-in-10",level:4},{value:"UserSelect",id:"userselect",level:3},{value:"Defined in",id:"defined-in-11",level:4}];function a(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",hr:"hr",p:"p",pre:"pre",strong:"strong",...(0,i.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Since"})})}),"\n",(0,r.jsx)(n.p,{children:"1.0.0\nA bitfield that discriminates command modules"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Example"})})}),"\n",(0,r.jsx)(n.pre,{children:(0,r.jsx)(n.code,{className:"language-ts",children:"export default commandModule({\n // highlight-next-line\n type : CommandType.Text,\n name : 'a text command'\n execute(message) {\n console.log(message.content)\n }\n})\n"})}),"\n",(0,r.jsx)(n.h2,{id:"enumeration-members",children:"Enumeration Members"}),"\n",(0,r.jsx)(n.h3,{id:"both",children:"Both"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"Both"})," = ",(0,r.jsx)(n.code,{children:"3"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/enums.ts#L20",children:"src/core/structures/enums.ts:20"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"button",children:"Button"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"Button"})," = ",(0,r.jsx)(n.code,{children:"16"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/enums.ts#L23",children:"src/core/structures/enums.ts:23"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"channelselect",children:"ChannelSelect"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"ChannelSelect"})," = ",(0,r.jsx)(n.code,{children:"1024"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/enums.ts#L29",children:"src/core/structures/enums.ts:29"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"ctxmsg",children:"CtxMsg"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"CtxMsg"})," = ",(0,r.jsx)(n.code,{children:"8"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/enums.ts#L22",children:"src/core/structures/enums.ts:22"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"ctxuser",children:"CtxUser"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"CtxUser"})," = ",(0,r.jsx)(n.code,{children:"4"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-4",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/enums.ts#L21",children:"src/core/structures/enums.ts:21"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"mentionableselect",children:"MentionableSelect"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"MentionableSelect"})," = ",(0,r.jsx)(n.code,{children:"512"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-5",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/enums.ts#L28",children:"src/core/structures/enums.ts:28"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"modal",children:"Modal"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"Modal"})," = ",(0,r.jsx)(n.code,{children:"64"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-6",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/enums.ts#L25",children:"src/core/structures/enums.ts:25"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"roleselect",children:"RoleSelect"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"RoleSelect"})," = ",(0,r.jsx)(n.code,{children:"256"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-7",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/enums.ts#L27",children:"src/core/structures/enums.ts:27"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"slash",children:"Slash"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"Slash"})," = ",(0,r.jsx)(n.code,{children:"2"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-8",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/enums.ts#L19",children:"src/core/structures/enums.ts:19"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"stringselect",children:"StringSelect"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"StringSelect"})," = ",(0,r.jsx)(n.code,{children:"32"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-9",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/enums.ts#L24",children:"src/core/structures/enums.ts:24"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"text",children:"Text"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"Text"})," = ",(0,r.jsx)(n.code,{children:"1"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-10",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/enums.ts#L18",children:"src/core/structures/enums.ts:18"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"userselect",children:"UserSelect"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"UserSelect"})," = ",(0,r.jsx)(n.code,{children:"128"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-11",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/enums.ts#L26",children:"src/core/structures/enums.ts:26"})})]})}function o(e={}){const{wrapper:n}={...(0,i.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(a,{...e})}):a(e)}},8453:(e,n,s)=>{s.d(n,{R:()=>l,x:()=>c});var r=s(6540);const i={},d=r.createContext(i);function l(e){const n=r.useContext(d);return r.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function c(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(i):e.components||i:l(e.components),r.createElement(d.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/a6aa9e1f.2d113433.js b/assets/js/a6aa9e1f.2d113433.js deleted file mode 100644 index 5cc081a8d..000000000 --- a/assets/js/a6aa9e1f.2d113433.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[7643],{7785:(e,t,n)=>{n.r(t),n.d(t,{default:()=>m});n(6540);var i=n(53),a=n(4586),r=n(9024),s=n(7559),l=n(6535),o=n(7713),d=n(1463),g=n(3892),c=n(4848);function p(e){const{metadata:t}=e,{siteConfig:{title:n}}=(0,a.A)(),{blogDescription:i,blogTitle:s,permalink:l}=t,o="/"===l?n:s;return(0,c.jsxs)(c.Fragment,{children:[(0,c.jsx)(r.be,{title:o,description:i}),(0,c.jsx)(d.A,{tag:"blog_posts_list"})]})}function h(e){const{metadata:t,items:n,sidebar:i}=e;return(0,c.jsxs)(l.A,{sidebar:i,children:[(0,c.jsx)(g.A,{items:n}),(0,c.jsx)(o.A,{metadata:t})]})}function m(e){return(0,c.jsxs)(r.e3,{className:(0,i.A)(s.G.wrapper.blogPages,s.G.page.blogListPage),children:[(0,c.jsx)(p,{...e}),(0,c.jsx)(h,{...e})]})}},7713:(e,t,n)=>{n.d(t,{A:()=>s});n(6540);var i=n(1312),a=n(9022),r=n(4848);function s(e){const{metadata:t}=e,{previousPage:n,nextPage:s}=t;return(0,r.jsxs)("nav",{className:"pagination-nav","aria-label":(0,i.T)({id:"theme.blog.paginator.navAriaLabel",message:"Blog list page navigation",description:"The ARIA label for the blog pagination"}),children:[n&&(0,r.jsx)(a.A,{permalink:n,title:(0,r.jsx)(i.A,{id:"theme.blog.paginator.newerEntries",description:"The label used to navigate to the newer blog posts page (previous page)",children:"Newer Entries"})}),s&&(0,r.jsx)(a.A,{permalink:s,title:(0,r.jsx)(i.A,{id:"theme.blog.paginator.olderEntries",description:"The label used to navigate to the older blog posts page (next page)",children:"Older Entries"}),isNext:!0})]})}},3892:(e,t,n)=>{n.d(t,{A:()=>s});n(6540);var i=n(7131),a=n(8258),r=n(4848);function s(e){let{items:t,component:n=a.A}=e;return(0,r.jsx)(r.Fragment,{children:t.map((e=>{let{content:t}=e;return(0,r.jsx)(i.i,{content:t,children:(0,r.jsx)(n,{children:(0,r.jsx)(t,{})})},t.metadata.permalink)}))})}},4428:(e,t,n)=>{n.d(t,{A:()=>o});var i=n(6540),a=n(2303),r=n(6846),s=n(3717),l=n(4848);function o(e){let{children:t,...n}=e;const o=(0,a.A)(),d=function(e){return i.Children.toArray(e).some((e=>(0,i.isValidElement)(e)))?e:Array.isArray(e)?e.join(""):e}(t),g="string"==typeof d?s.A:r.A;return(0,l.jsx)(g,{...n,children:d},String(o))}}}]); \ No newline at end of file diff --git a/assets/js/a6d8dddc.72dbc8e5.js b/assets/js/a6d8dddc.72dbc8e5.js deleted file mode 100644 index 96a8a7b35..000000000 --- a/assets/js/a6d8dddc.72dbc8e5.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[3033],{9088:(e,n,r)=>{r.r(n),r.d(n,{assets:()=>l,contentTitle:()=>d,default:()=>h,frontMatter:()=>i,metadata:()=>o,toc:()=>c});var s=r(4848),t=r(8453);const i={id:"CommandError.Response",title:"Interface: Response",sidebar_label:"Response",custom_edit_url:null},d=void 0,o={id:"api/interfaces/CommandError.Response",title:"Interface: Response",description:"CommandError.Response",source:"@site/docs/api/interfaces/CommandError.Response.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/CommandError.Response",permalink:"/docs/api/interfaces/CommandError.Response",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",frontMatter:{id:"CommandError.Response",title:"Interface: Response",sidebar_label:"Response",custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"Wrapper",permalink:"/docs/api/interfaces/Wrapper"},next:{title:"Result",permalink:"/docs/api/interfaces/Presence.Result"}},l={},c=[{value:"Properties",id:"properties",level:2},{value:"body",id:"body",level:3},{value:"Defined in",id:"defined-in",level:4},{value:"log",id:"log",level:3},{value:"Type declaration",id:"type-declaration",level:4},{value:"Defined in",id:"defined-in-1",level:4},{value:"type",id:"type",level:3},{value:"Defined in",id:"defined-in-2",level:4}];function a(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",hr:"hr",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,t.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.a,{href:"/docs/api/namespaces/CommandError",children:"CommandError"}),".Response"]}),"\n",(0,s.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,s.jsx)(n.h3,{id:"body",children:"body"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"Optional"})," ",(0,s.jsx)(n.strong,{children:"body"}),": ",(0,s.jsx)(n.code,{children:"ReplyOptions"})]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/504cdee/src/core/structures/command-error.ts#L6",children:"src/core/structures/command-error.ts:6"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"log",children:"log"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"Optional"})," ",(0,s.jsx)(n.strong,{children:"log"}),": ",(0,s.jsx)(n.code,{children:"Object"})]}),"\n",(0,s.jsx)(n.h4,{id:"type-declaration",children:"Type declaration"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,s.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,s.jsxs)(n.tbody,{children:[(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{style:{textAlign:"left"},children:(0,s.jsx)(n.code,{children:"message"})}),(0,s.jsx)(n.td,{style:{textAlign:"left"},children:(0,s.jsx)(n.code,{children:"unknown"})})]}),(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{style:{textAlign:"left"},children:(0,s.jsx)(n.code,{children:"type"})}),(0,s.jsxs)(n.td,{style:{textAlign:"left"},children:["keyof ",(0,s.jsx)(n.a,{href:"/docs/api/interfaces/Logging",children:(0,s.jsx)(n.code,{children:"Logging"})}),"<",(0,s.jsx)(n.code,{children:"unknown"}),">"]})]})]})]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/504cdee/src/core/structures/command-error.ts#L7",children:"src/core/structures/command-error.ts:7"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"type",children:"type"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.strong,{children:"type"}),": ",(0,s.jsx)(n.code,{children:'"fail"'})," | ",(0,s.jsx)(n.code,{children:'"continue"'})]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/504cdee/src/core/structures/command-error.ts#L5",children:"src/core/structures/command-error.ts:5"})})]})}function h(e={}){const{wrapper:n}={...(0,t.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(a,{...e})}):a(e)}},8453:(e,n,r)=>{r.d(n,{R:()=>d,x:()=>o});var s=r(6540);const t={},i=s.createContext(t);function d(e){const n=s.useContext(i);return s.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function o(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(t):e.components||t:d(e.components),s.createElement(i.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/a7023ddc.6615db4d.js b/assets/js/a7023ddc.6615db4d.js deleted file mode 100644 index 77e306788..000000000 --- a/assets/js/a7023ddc.6615db4d.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[9267],{8289:e=>{e.exports=JSON.parse('[{"label":"guides","permalink":"/blog/tags/guides","count":2},{"label":"branding","permalink":"/blog/tags/branding","count":1},{"label":"release","permalink":"/blog/tags/release","count":4}]')}}]); \ No newline at end of file diff --git a/assets/js/a727fde1.b20a2b9a.js b/assets/js/a727fde1.b20a2b9a.js deleted file mode 100644 index fd9d2b4eb..000000000 --- a/assets/js/a727fde1.b20a2b9a.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[5342],{1438:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>a,contentTitle:()=>o,default:()=>u,frontMatter:()=>r,metadata:()=>c,toc:()=>d});var i=t(4848),s=t(8453);const r={id:"Init",title:"Interface: Init",sidebar_label:"Init",sidebar_position:0,custom_edit_url:null},o=void 0,c={id:"api/interfaces/Init",title:"Interface: Init",description:"Represents an initialization contract.",source:"@site/docs/api/interfaces/Init.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/Init",permalink:"/docs/api/interfaces/Init",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"Init",title:"Interface: Init",sidebar_label:"Init",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"ExternalEventPlugin",permalink:"/docs/api/interfaces/ExternalEventPlugin"},next:{title:"InitArgs",permalink:"/docs/api/interfaces/InitArgs"}},a={},d=[{value:"Methods",id:"methods",level:2},{value:"init",id:"init",level:3},{value:"Returns",id:"returns",level:4},{value:"Defined in",id:"defined-in",level:4}];function l(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",p:"p",strong:"strong",...(0,s.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(n.p,{children:"Represents an initialization contract.\nLet dependencies implement this to initiate some logic."}),"\n",(0,i.jsx)(n.h2,{id:"methods",children:"Methods"}),"\n",(0,i.jsx)(n.h3,{id:"init",children:"init"}),"\n",(0,i.jsxs)(n.p,{children:["\u25b8 ",(0,i.jsx)(n.strong,{children:"init"}),"(): ",(0,i.jsx)(n.code,{children:"unknown"})]}),"\n",(0,i.jsx)(n.h4,{id:"returns",children:"Returns"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.code,{children:"unknown"})}),"\n",(0,i.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/contracts/hooks.ts#L7",children:"src/core/contracts/hooks.ts:7"})})]})}function u(e={}){const{wrapper:n}={...(0,s.R)(),...e.components};return n?(0,i.jsx)(n,{...e,children:(0,i.jsx)(l,{...e})}):l(e)}},8453:(e,n,t)=>{t.d(n,{R:()=>o,x:()=>c});var i=t(6540);const s={},r=i.createContext(s);function o(e){const n=i.useContext(r);return i.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function c(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:o(e.components),i.createElement(r.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/a7bd4aaa.5a4646c2.js b/assets/js/a7bd4aaa.5a4646c2.js deleted file mode 100644 index 7b890578f..000000000 --- a/assets/js/a7bd4aaa.5a4646c2.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[7098],{4532:(e,n,s)=>{s.r(n),s.d(n,{default:()=>x});s(6540);var r=s(9024),t=s(2967),o=s(2252),i=s(2831),c=s(1463),u=s(4848);function a(e){const{version:n}=e;return(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(c.A,{version:n.version,tag:(0,t.tU)(n.pluginId,n.version)}),(0,u.jsx)(r.be,{children:n.noIndex&&(0,u.jsx)("meta",{name:"robots",content:"noindex, nofollow"})})]})}function l(e){const{version:n,route:s}=e;return(0,u.jsx)(r.e3,{className:n.className,children:(0,u.jsx)(o.n,{version:n,children:(0,i.v)(s.routes)})})}function x(e){return(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(a,{...e}),(0,u.jsx)(l,{...e})]})}}}]); \ No newline at end of file diff --git a/assets/js/a94703ab.35d0f890.js b/assets/js/a94703ab.35d0f890.js deleted file mode 100644 index 39b4b8aa8..000000000 --- a/assets/js/a94703ab.35d0f890.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[9048],{2559:(e,t,n)=>{n.r(t),n.d(t,{default:()=>be});var a=n(6540),o=n(53),i=n(9024),s=n(7559),l=n(1754),r=n(6588),c=n(1312),d=n(3104),u=n(5062);const m={backToTopButton:"backToTopButton_sjWU",backToTopButtonShow:"backToTopButtonShow_xfvO"};var b=n(4848);function h(){const{shown:e,scrollToTop:t}=function(e){let{threshold:t}=e;const[n,o]=(0,a.useState)(!1),i=(0,a.useRef)(!1),{startScroll:s,cancelScroll:l}=(0,d.gk)();return(0,d.Mq)(((e,n)=>{let{scrollY:a}=e;const s=n?.scrollY;s&&(i.current?i.current=!1:a>=s?(l(),o(!1)):a {e.location.hash&&(i.current=!0,o(!1))})),{shown:n,scrollToTop:()=>s(0)}}({threshold:300});return(0,b.jsx)("button",{"aria-label":(0,c.T)({id:"theme.BackToTopButton.buttonAriaLabel",message:"Scroll back to top",description:"The ARIA label for the back to top button"}),className:(0,o.A)("clean-btn",s.G.common.backToTopButton,m.backToTopButton,e&&m.backToTopButtonShow),type:"button",onClick:t})}var p=n(3109),x=n(6347),j=n(4581),f=n(6342),_=n(3465);function v(e){return(0,b.jsx)("svg",{width:"20",height:"20","aria-hidden":"true",...e,children:(0,b.jsxs)("g",{fill:"#7a7a7a",children:[(0,b.jsx)("path",{d:"M9.992 10.023c0 .2-.062.399-.172.547l-4.996 7.492a.982.982 0 01-.828.454H1c-.55 0-1-.453-1-1 0-.2.059-.403.168-.551l4.629-6.942L.168 3.078A.939.939 0 010 2.528c0-.548.45-.997 1-.997h2.996c.352 0 .649.18.828.45L9.82 9.472c.11.148.172.347.172.55zm0 0"}),(0,b.jsx)("path",{d:"M19.98 10.023c0 .2-.058.399-.168.547l-4.996 7.492a.987.987 0 01-.828.454h-3c-.547 0-.996-.453-.996-1 0-.2.059-.403.168-.551l4.625-6.942-4.625-6.945a.939.939 0 01-.168-.55 1 1 0 01.996-.997h3c.348 0 .649.18.828.45l4.996 7.492c.11.148.168.347.168.55zm0 0"})]})})}const A={collapseSidebarButton:"collapseSidebarButton_PEFL",collapseSidebarButtonIcon:"collapseSidebarButtonIcon_kv0_"};function g(e){let{onClick:t}=e;return(0,b.jsx)("button",{type:"button",title:(0,c.T)({id:"theme.docs.sidebar.collapseButtonTitle",message:"Collapse sidebar",description:"The title attribute for collapse button of doc sidebar"}),"aria-label":(0,c.T)({id:"theme.docs.sidebar.collapseButtonAriaLabel",message:"Collapse sidebar",description:"The title attribute for collapse button of doc sidebar"}),className:(0,o.A)("button button--secondary button--outline",A.collapseSidebarButton),onClick:t,children:(0,b.jsx)(v,{className:A.collapseSidebarButtonIcon})})}var k=n(5041),C=n(9532);const S=Symbol("EmptyContext"),T=a.createContext(S);function N(e){let{children:t}=e;const[n,o]=(0,a.useState)(null),i=(0,a.useMemo)((()=>({expandedItem:n,setExpandedItem:o})),[n]);return(0,b.jsx)(T.Provider,{value:i,children:t})}var I=n(1422),B=n(9169),y=n(5489),w=n(2303);function L(e){let{collapsed:t,categoryLabel:n,onClick:a}=e;return(0,b.jsx)("button",{"aria-label":t?(0,c.T)({id:"theme.DocSidebarItem.expandCategoryAriaLabel",message:"Expand sidebar category '{label}'",description:"The ARIA label to expand the sidebar category"},{label:n}):(0,c.T)({id:"theme.DocSidebarItem.collapseCategoryAriaLabel",message:"Collapse sidebar category '{label}'",description:"The ARIA label to collapse the sidebar category"},{label:n}),type:"button",className:"clean-btn menu__caret",onClick:a})}function E(e){let{item:t,onItemClick:n,activePath:i,level:r,index:c,...d}=e;const{items:u,label:m,collapsible:h,className:p,href:x}=t,{docs:{sidebar:{autoCollapseCategories:j}}}=(0,f.p)(),_=function(e){const t=(0,w.A)();return(0,a.useMemo)((()=>e.href&&!e.linkUnlisted?e.href:!t&&e.collapsible?(0,l.Nr)(e):void 0),[e,t])}(t),v=(0,l.w8)(t,i),A=(0,B.ys)(x,i),{collapsed:g,setCollapsed:k}=(0,I.u)({initialState:()=>!!h&&(!v&&t.collapsed)}),{expandedItem:N,setExpandedItem:E}=function(){const e=(0,a.useContext)(T);if(e===S)throw new C.dV("DocSidebarItemsExpandedStateProvider");return e}(),M=function(e){void 0===e&&(e=!g),E(e?null:c),k(e)};return function(e){let{isActive:t,collapsed:n,updateCollapsed:o}=e;const i=(0,C.ZC)(t);(0,a.useEffect)((()=>{t&&!i&&n&&o(!1)}),[t,i,n,o])}({isActive:v,collapsed:g,updateCollapsed:M}),(0,a.useEffect)((()=>{h&&null!=N&&N!==c&&j&&k(!0)}),[h,N,c,k,j]),(0,b.jsxs)("li",{className:(0,o.A)(s.G.docs.docSidebarItemCategory,s.G.docs.docSidebarItemCategoryLevel(r),"menu__list-item",{"menu__list-item--collapsed":g},p),children:[(0,b.jsxs)("div",{className:(0,o.A)("menu__list-item-collapsible",{"menu__list-item-collapsible--active":A}),children:[(0,b.jsx)(y.A,{className:(0,o.A)("menu__link",{"menu__link--sublist":h,"menu__link--sublist-caret":!x&&h,"menu__link--active":v}),onClick:h?e=>{n?.(t),x?M(!1):(e.preventDefault(),M())}:()=>{n?.(t)},"aria-current":A?"page":void 0,"aria-expanded":h?!g:void 0,href:h?_??"#":_,...d,children:m}),x&&h&&(0,b.jsx)(L,{collapsed:g,categoryLabel:m,onClick:e=>{e.preventDefault(),M()}})]}),(0,b.jsx)(I.N,{lazy:!0,as:"ul",className:"menu__list",collapsed:g,children:(0,b.jsx)(U,{items:u,tabIndex:g?-1:0,onItemClick:n,activePath:i,level:r+1})})]})}var M=n(6654),H=n(3186);const G={menuExternalLink:"menuExternalLink_NmtK"};function W(e){let{item:t,onItemClick:n,activePath:a,level:i,index:r,...c}=e;const{href:d,label:u,className:m,autoAddBaseUrl:h}=t,p=(0,l.w8)(t,a),x=(0,M.A)(d);return(0,b.jsx)("li",{className:(0,o.A)(s.G.docs.docSidebarItemLink,s.G.docs.docSidebarItemLinkLevel(i),"menu__list-item",m),children:(0,b.jsxs)(y.A,{className:(0,o.A)("menu__link",!x&&G.menuExternalLink,{"menu__link--active":p}),autoAddBaseUrl:h,"aria-current":p?"page":void 0,to:d,...x&&{onClick:n?()=>n(t):void 0},...c,children:[u,!x&&(0,b.jsx)(H.A,{})]})},u)}const P={menuHtmlItem:"menuHtmlItem_M9Kj"};function R(e){let{item:t,level:n,index:a}=e;const{value:i,defaultStyle:l,className:r}=t;return(0,b.jsx)("li",{className:(0,o.A)(s.G.docs.docSidebarItemLink,s.G.docs.docSidebarItemLinkLevel(n),l&&[P.menuHtmlItem,"menu__list-item"],r),dangerouslySetInnerHTML:{__html:i}},a)}function D(e){let{item:t,...n}=e;switch(t.type){case"category":return(0,b.jsx)(E,{item:t,...n});case"html":return(0,b.jsx)(R,{item:t,...n});default:return(0,b.jsx)(W,{item:t,...n})}}function F(e){let{items:t,...n}=e;const a=(0,l.Y)(t,n.activePath);return(0,b.jsx)(N,{children:a.map(((e,t)=>(0,b.jsx)(D,{item:e,index:t,...n},t)))})}const U=(0,a.memo)(F),V={menu:"menu_SIkG",menuWithAnnouncementBar:"menuWithAnnouncementBar_GW3s"};function Y(e){let{path:t,sidebar:n,className:i}=e;const l=function(){const{isActive:e}=(0,k.Mj)(),[t,n]=(0,a.useState)(e);return(0,d.Mq)((t=>{let{scrollY:a}=t;e&&n(0===a)}),[e]),e&&t}();return(0,b.jsx)("nav",{"aria-label":(0,c.T)({id:"theme.docs.sidebar.navAriaLabel",message:"Docs sidebar",description:"The ARIA label for the sidebar navigation"}),className:(0,o.A)("menu thin-scrollbar",V.menu,l&&V.menuWithAnnouncementBar,i),children:(0,b.jsx)("ul",{className:(0,o.A)(s.G.docs.docSidebarMenu,"menu__list"),children:(0,b.jsx)(U,{items:n,activePath:t,level:1})})})}const K="sidebar_njMd",z="sidebarWithHideableNavbar_wUlq",q="sidebarHidden_VK0M",O="sidebarLogo_isFc";function J(e){let{path:t,sidebar:n,onCollapse:a,isHidden:i}=e;const{navbar:{hideOnScroll:s},docs:{sidebar:{hideable:l}}}=(0,f.p)();return(0,b.jsxs)("div",{className:(0,o.A)(K,s&&z,i&&q),children:[s&&(0,b.jsx)(_.A,{tabIndex:-1,className:O}),(0,b.jsx)(Y,{path:t,sidebar:n}),l&&(0,b.jsx)(g,{onClick:a})]})}const Q=a.memo(J);var X=n(5600),Z=n(2069);const $=e=>{let{sidebar:t,path:n}=e;const a=(0,Z.M)();return(0,b.jsx)("ul",{className:(0,o.A)(s.G.docs.docSidebarMenu,"menu__list"),children:(0,b.jsx)(U,{items:t,activePath:n,onItemClick:e=>{"category"===e.type&&e.href&&a.toggle(),"link"===e.type&&a.toggle()},level:1})})};function ee(e){return(0,b.jsx)(X.GX,{component:$,props:e})}const te=a.memo(ee);function ne(e){const t=(0,j.l)(),n="desktop"===t||"ssr"===t,a="mobile"===t;return(0,b.jsxs)(b.Fragment,{children:[n&&(0,b.jsx)(Q,{...e}),a&&(0,b.jsx)(te,{...e})]})}const ae={expandButton:"expandButton_TmdG",expandButtonIcon:"expandButtonIcon_i1dp"};function oe(e){let{toggleSidebar:t}=e;return(0,b.jsx)("div",{className:ae.expandButton,title:(0,c.T)({id:"theme.docs.sidebar.expandButtonTitle",message:"Expand sidebar",description:"The ARIA label and title attribute for expand button of doc sidebar"}),"aria-label":(0,c.T)({id:"theme.docs.sidebar.expandButtonAriaLabel",message:"Expand sidebar",description:"The ARIA label and title attribute for expand button of doc sidebar"}),tabIndex:0,role:"button",onKeyDown:t,onClick:t,children:(0,b.jsx)(v,{className:ae.expandButtonIcon})})}const ie={docSidebarContainer:"docSidebarContainer_YfHR",docSidebarContainerHidden:"docSidebarContainerHidden_DPk8",sidebarViewport:"sidebarViewport_aRkj"};function se(e){let{children:t}=e;const n=(0,r.t)();return(0,b.jsx)(a.Fragment,{children:t},n?.name??"noSidebar")}function le(e){let{sidebar:t,hiddenSidebarContainer:n,setHiddenSidebarContainer:i}=e;const{pathname:l}=(0,x.zy)(),[r,c]=(0,a.useState)(!1),d=(0,a.useCallback)((()=>{r&&c(!1),!r&&(0,p.O)()&&c(!0),i((e=>!e))}),[i,r]);return(0,b.jsx)("aside",{className:(0,o.A)(s.G.docs.docSidebarContainer,ie.docSidebarContainer,n&&ie.docSidebarContainerHidden),onTransitionEnd:e=>{e.currentTarget.classList.contains(ie.docSidebarContainer)&&n&&c(!0)},children:(0,b.jsx)(se,{children:(0,b.jsxs)("div",{className:(0,o.A)(ie.sidebarViewport,r&&ie.sidebarViewportHidden),children:[(0,b.jsx)(ne,{sidebar:t,path:l,onCollapse:d,isHidden:r}),r&&(0,b.jsx)(oe,{toggleSidebar:d})]})})})}const re={docMainContainer:"docMainContainer_TBSr",docMainContainerEnhanced:"docMainContainerEnhanced_lQrH",docItemWrapperEnhanced:"docItemWrapperEnhanced_JWYK"};function ce(e){let{hiddenSidebarContainer:t,children:n}=e;const a=(0,r.t)();return(0,b.jsx)("main",{className:(0,o.A)(re.docMainContainer,(t||!a)&&re.docMainContainerEnhanced),children:(0,b.jsx)("div",{className:(0,o.A)("container padding-top--md padding-bottom--lg",re.docItemWrapper,t&&re.docItemWrapperEnhanced),children:n})})}const de={docRoot:"docRoot_UBD9",docsWrapper:"docsWrapper_hBAB"};function ue(e){let{children:t}=e;const n=(0,r.t)(),[o,i]=(0,a.useState)(!1);return(0,b.jsxs)("div",{className:de.docsWrapper,children:[(0,b.jsx)(h,{}),(0,b.jsxs)("div",{className:de.docRoot,children:[n&&(0,b.jsx)(le,{sidebar:n.items,hiddenSidebarContainer:o,setHiddenSidebarContainer:i}),(0,b.jsx)(ce,{hiddenSidebarContainer:o,children:t})]})]})}var me=n(3363);function be(e){const t=(0,l.B5)(e);if(!t)return(0,b.jsx)(me.A,{});const{docElement:n,sidebarName:a,sidebarItems:c}=t;return(0,b.jsx)(i.e3,{className:(0,o.A)(s.G.page.docsDocPage),children:(0,b.jsx)(r.V,{name:a,items:c,children:(0,b.jsx)(ue,{children:n})})})}},3363:(e,t,n)=>{n.d(t,{A:()=>l});n(6540);var a=n(53),o=n(1312),i=n(1107),s=n(4848);function l(e){let{className:t}=e;return(0,s.jsx)("main",{className:(0,a.A)("container margin-vert--xl",t),children:(0,s.jsx)("div",{className:"row",children:(0,s.jsxs)("div",{className:"col col--6 col--offset-3",children:[(0,s.jsx)(i.A,{as:"h1",className:"hero__title",children:(0,s.jsx)(o.A,{id:"theme.NotFound.title",description:"The title of the 404 page",children:"Page Not Found"})}),(0,s.jsx)("p",{children:(0,s.jsx)(o.A,{id:"theme.NotFound.p1",description:"The first paragraph of the 404 page",children:"We could not find what you were looking for."})}),(0,s.jsx)("p",{children:(0,s.jsx)(o.A,{id:"theme.NotFound.p2",description:"The 2nd paragraph of the 404 page",children:"Please contact the owner of the site that linked you to the original URL and let them know their link is broken."})})]})})})}}}]); \ No newline at end of file diff --git a/assets/js/a96c96b0.f3e38592.js b/assets/js/a96c96b0.f3e38592.js deleted file mode 100644 index 893ef58d4..000000000 --- a/assets/js/a96c96b0.f3e38592.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[3295],{6829:(e,n,t)=>{t.r(n),t.d(n,{assets:()=>l,contentTitle:()=>o,default:()=>u,frontMatter:()=>s,metadata:()=>a,toc:()=>d});var i=t(4848),r=t(8453);const s={sidebar_position:1},o="Goal",a={id:"guide/walkthrough/goal",title:"Goal",description:"This walkthrough will be written in TypeScript but will have JavaScript snippets throughout.",source:"@site/docs/guide/walkthrough/goal.md",sourceDirName:"guide/walkthrough",slug:"/guide/walkthrough/goal",permalink:"/docs/guide/walkthrough/goal",draft:!1,unlisted:!1,editUrl:"https://github.com/sern-handler/website/edit/main/docs/guide/walkthrough/goal.md",tags:[],version:"current",sidebarPosition:1,frontMatter:{sidebar_position:1},sidebar:"tutorialSidebar",previous:{title:"Preparing to Code",permalink:"/docs/guide/getting-started/preparing"},next:{title:"Create a new project",permalink:"/docs/guide/walkthrough/new-project"}},l={},d=[{value:"Using @sapphire/framework",id:"using-sapphireframework",level:3},{value:"Using @sern/handler",id:"using-sernhandler",level:3}];function c(e){const n={a:"a",code:"code",em:"em",h1:"h1",h3:"h3",li:"li",p:"p",pre:"pre",ul:"ul",...(0,r.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(n.h1,{id:"goal",children:"Goal"}),"\n",(0,i.jsxs)(n.p,{children:["This walkthrough will be written in ",(0,i.jsx)(n.a,{href:"https://www.typescriptlang.org/",children:"TypeScript"})," but will have JavaScript snippets throughout."]}),"\n",(0,i.jsx)(n.h1,{id:"make-robust-modular-bots",children:"Make robust, modular, bots"}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.em,{children:"Modularity"}),": sern is built with modularity in mind. You can swap pieces and parts easily."]}),"\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.em,{children:"Familiar"}),": commands and structures are similar to classic v12 handlers and the official discord.js command handler guide, while packing many features"]}),"\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.em,{children:"Concise"}),": Too much code is a liability. with sern, write less for more \ud83e\udd2f"]}),"\n"]}),"\n",(0,i.jsx)(n.h3,{id:"using-sapphireframework",children:"Using @sapphire/framework"}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-ts",metastring:'title="commands/ping.ts" showLineNumbers',children:"import { Command } from '@sapphire/framework'\nimport type { CommandInteraction } from 'discord.js'\n\nexport class PingCommand extends Command {\n public constructor(context: Command.Context) {\n super(context, {\n description: 'Pong!',\n chatInputCommand: {\n register: true,\n },\n })\n }\n public async chatInputRun(interaction: CommandInteraction) {\n await interaction.reply('Pong!')\n }\n}\n"})}),"\n",(0,i.jsx)(n.h3,{id:"using-sernhandler",children:"Using @sern/handler"}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-ts",metastring:'title="commands/ping.ts" showLineNumbers',children:"import { commandModule, CommandType } from '@sern/handler'\nimport { publish } from '../plugins';\n\nexport default commandModule({ \n type: CommandType.Both,\n plugins: [publish()],\n description: 'Pong!',\n execute: (ctx, args) => {\n await ctx.reply('Pong!')\n }\n})\n"})}),"\n",(0,i.jsx)(n.p,{children:"Keep in mind the above example acts as both a slash command AND text command"})]})}function u(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,i.jsx)(n,{...e,children:(0,i.jsx)(c,{...e})}):c(e)}},8453:(e,n,t)=>{t.d(n,{R:()=>o,x:()=>a});var i=t(6540);const r={},s=i.createContext(r);function o(e){const n=i.useContext(s);return i.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function a(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(r):e.components||r:o(e.components),i.createElement(s.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/b134d7b8.f1083d8d.js b/assets/js/b134d7b8.f1083d8d.js deleted file mode 100644 index 47e5f3556..000000000 --- a/assets/js/b134d7b8.f1083d8d.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[5068],{9775:(e,n,i)=>{i.r(n),i.d(n,{assets:()=>a,contentTitle:()=>t,default:()=>h,frontMatter:()=>s,metadata:()=>l,toc:()=>c});var r=i(4848),d=i(8453);const s={id:"SernEventsMapping",title:"Interface: SernEventsMapping",sidebar_label:"SernEventsMapping",sidebar_position:0,custom_edit_url:null},t=void 0,l={id:"api/interfaces/SernEventsMapping",title:"Interface: SernEventsMapping",description:"Properties",source:"@site/docs/api/interfaces/SernEventsMapping.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/SernEventsMapping",permalink:"/docs/api/interfaces/SernEventsMapping",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"SernEventsMapping",title:"Interface: SernEventsMapping",sidebar_label:"SernEventsMapping",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"SernEventPlugin",permalink:"/docs/api/interfaces/SernEventPlugin"},next:{title:"SernSubCommandData",permalink:"/docs/api/interfaces/SernSubCommandData"}},a={},c=[{value:"Properties",id:"properties",level:2},{value:"error",id:"error",level:3},{value:"Defined in",id:"defined-in",level:4},{value:"module.activate",id:"moduleactivate",level:3},{value:"Defined in",id:"defined-in-1",level:4},{value:"module.register",id:"moduleregister",level:3},{value:"Defined in",id:"defined-in-2",level:4},{value:"modulesLoaded",id:"modulesloaded",level:3},{value:"Defined in",id:"defined-in-3",level:4},{value:"warning",id:"warning",level:3},{value:"Defined in",id:"defined-in-4",level:4}];function o(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",hr:"hr",p:"p",strong:"strong",...(0,d.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,r.jsx)(n.h3,{id:"error",children:"error"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"error"}),": [{ ",(0,r.jsx)(n.code,{children:"module?"}),": ",(0,r.jsx)(n.code,{children:"AnyModule"})," ; ",(0,r.jsx)(n.code,{children:"reason"}),": ",(0,r.jsx)(n.code,{children:"string"})," | ",(0,r.jsx)(n.code,{children:"Error"})," ; ",(0,r.jsx)(n.code,{children:"type"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/enums/PayloadType#failure",children:(0,r.jsx)(n.code,{children:"Failure"})})," }]"]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/utility.ts#L21",children:"src/types/utility.ts:21"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"moduleactivate",children:"module.activate"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"module.activate"}),": [",(0,r.jsx)(n.a,{href:"/docs/api/modules#payload",children:(0,r.jsx)(n.code,{children:"Payload"})}),"]"]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/utility.ts#L20",children:"src/types/utility.ts:20"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"moduleregister",children:"module.register"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"module.register"}),": [",(0,r.jsx)(n.a,{href:"/docs/api/modules#payload",children:(0,r.jsx)(n.code,{children:"Payload"})}),"]"]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/utility.ts#L19",children:"src/types/utility.ts:19"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"modulesloaded",children:"modulesLoaded"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"modulesLoaded"}),": [undefined?]"]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/utility.ts#L23",children:"src/types/utility.ts:23"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"warning",children:"warning"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"warning"}),": [",(0,r.jsx)(n.a,{href:"/docs/api/modules#payload",children:(0,r.jsx)(n.code,{children:"Payload"})}),"]"]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-4",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/types/utility.ts#L22",children:"src/types/utility.ts:22"})})]})}function h(e={}){const{wrapper:n}={...(0,d.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(o,{...e})}):o(e)}},8453:(e,n,i)=>{i.d(n,{R:()=>t,x:()=>l});var r=i(6540);const d={},s=r.createContext(d);function t(e){const n=r.useContext(s);return r.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function l(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(d):e.components||d:t(e.components),r.createElement(s.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/b2b675dd.3bcec961.js b/assets/js/b2b675dd.3bcec961.js deleted file mode 100644 index 46343c17f..000000000 --- a/assets/js/b2b675dd.3bcec961.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[1991],{2156:e=>{e.exports=JSON.parse('{"permalink":"/blog","page":1,"postsPerPage":10,"totalPages":1,"totalCount":7,"blogDescription":"Blog","blogTitle":"Blog"}')}}]); \ No newline at end of file diff --git a/assets/js/b2f554cd.11ce5c09.js b/assets/js/b2f554cd.11ce5c09.js deleted file mode 100644 index c5ded9121..000000000 --- a/assets/js/b2f554cd.11ce5c09.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[5894],{6042:e=>{e.exports=JSON.parse('{"blogPosts":[{"id":"railway-deploy","metadata":{"permalink":"/blog/railway-deploy","editUrl":"https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/blog/2024-02-23-mdx-blog-post.md","source":"@site/blog/2024-02-23-mdx-blog-post.md","title":"Deploying sern with Railway","description":"In this guide, I\'ll be showing you how to deploy your sern bot with Railway.","date":"2024-02-23T00:00:00.000Z","formattedDate":"February 23, 2024","tags":[{"label":"guides","permalink":"/blog/tags/guides"}],"readingTime":1.47,"hasTruncateMarker":false,"authors":[{"name":"Duro","title":"Developer","url":"https://github.com/DuroCodes","imageURL":"https://github.com/DuroCodes.png","key":"Duro"}],"frontMatter":{"slug":"railway-deploy","title":"Deploying sern with Railway","authors":["Duro"],"tags":["guides"]},"unlisted":false,"nextItem":{"title":"New logo!","permalink":"/blog/newlogo"}},"content":"In this guide, I\'ll be showing you how to deploy your sern bot with [Railway](https://railway.app/).\\n\\nThis guide assumes you have a sern bot already set up and ready to deploy. If you don\'t, you can follow the [Getting Started](/blog/getting-started) guide to set up your bot.\\n\\n## GitHub Repository\\n\\nThe first thing you\'ll need to deploy your bot is a GitHub repository for your bot. If you don\'t have one, you can create one by following the [GitHub guide](https://docs.github.com/en/get-started/quickstart/create-a-repo).\\n\\nOnce you have your repository set up, you can push your bot\'s code to the repository, and you\'re ready to deploy using Railway.\\n\\n## Railway Setup\\n\\nAfter you have your bot\'s code in a GitHub repository, you\'ll need to create an account on Railway. You can sign up using your GitHub account at [railway.app](https://railway.app/).\\n\\nOnce you\'ve created your account, navigate to the [dashboard](https://railway.app/dashboard) and click the \\"New Project\\" button. Click the \\"Deploy from GitHub repo\\" button, and select your bot\'s repository.\\n\\nOnce you\'ve selected your repository, click the \\"Add Variables\\" button to add your bot\'s environment variables. You\'ll need your environment variables from your `.env` file to add to Railway. (You can also add these later if you want.)\\n\\n## Deploy\\n\\nOnce you\'ve added your environment variables, click the \\"Deploy\\" button, and Railway will start deploying your bot. Once the deployment is complete, you\'ll be able to see your bot\'s URL and logs.\\n\\n:::note\\nMake sure you add your environment variables, and your node start script is correct in your `package.json` file.\\n\\nIf you have any issues deploying your bot, you can check the logs for any errors.\\n:::\\n\\nThat\'s it! Your bot is now deployed and running on Railway. If you have any issues or questions, feel free to ask in the [sern Discord server](https://sern.dev/discord)."},{"id":"newlogo","metadata":{"permalink":"/blog/newlogo","editUrl":"https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/blog/2023-7-4-mdx-blog-post.md","source":"@site/blog/2023-7-4-mdx-blog-post.md","title":"New logo!","description":"Hey everyone! Today we have very special news for you all: We\'re changing our logo!","date":"2023-07-04T00:00:00.000Z","formattedDate":"July 4, 2023","tags":[{"label":"branding","permalink":"/blog/tags/branding"}],"readingTime":0.83,"hasTruncateMarker":false,"authors":[{"name":"sern Team","url":"https://github.com/sern-handler","imageURL":"https://github.com/sernbot.png","key":"sern"}],"frontMatter":{"slug":"newlogo","title":"New logo!","authors":["sern"],"tags":["branding"]},"unlisted":false,"prevItem":{"title":"Deploying sern with Railway","permalink":"/blog/railway-deploy"},"nextItem":{"title":"Release 3.0.0","permalink":"/blog/3.0.0"}},"content":"Hey everyone! Today we have very special news for you all: We\'re changing our logo!\\n\\n# Why?\\n\\nYou see, on today\'s standards, having a simple logo is essential. Our logo aligns perfectly with these design principles but it can always be improved. \\nWe were chilling, you know, cooking sern handler v3, sern gui, `npm create @sern/bot` and serncord when we thought about changing the logo to a sleek design with less colors. \\nAnd here we are!\\n\\n# Who did our new branding?\\n\\n[Ropox](https://github.com/Murtatrxx)! \\nBro\'s the GOAT. This website is maintained by him, the domain costs are funded by him and also he started brainstorming how the logo would be on paper: \\n\\nAnd there it all clicked: \\n\\nseren tried by the way!\\n\\n\\n# Anyways, here it is:\\n\\n\\n\\nPretty nice!\\n\\nBy the way, we have animations and variations on the way, so make sure to stay updated in the [discord server](https://sern.dev/discord)!\\n\\n# Finally, from the entire sern team, thank you for sticking around \u2764\ufe0f"},{"id":"3.0.0","metadata":{"permalink":"/blog/3.0.0","editUrl":"https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/blog/2023-06-18-mdx-blog-post.md","source":"@site/blog/2023-06-18-mdx-blog-post.md","title":"Release 3.0.0","description":"3.0 Release","date":"2023-06-18T00:00:00.000Z","formattedDate":"June 18, 2023","tags":[{"label":"release","permalink":"/blog/tags/release"}],"readingTime":2.475,"hasTruncateMarker":false,"authors":[{"name":"jacoobes","title":"Head Dev","url":"https://github.com/jacoobes","imageURL":"https://github.com/jacoobes.png","key":"jacoobes"}],"frontMatter":{"slug":"3.0.0","title":"Release 3.0.0","authors":["jacoobes"],"tags":["release"]},"unlisted":false,"prevItem":{"title":"New logo!","permalink":"/blog/newlogo"},"nextItem":{"title":"Release 2.5.0","permalink":"/blog/2.5.0"}},"content":"## 3.0 Release\\n\\n### Join our [discord](https://sern.dev/discord)
\\n\\n### Features\\n\\n#### Dependency Management\\n- `Service` API (recommended to use this over useContainer hooks)\\n - Dependencies type must be globally augmented in order for Services api to function properly\\n- new methods on ModuleManager\\n - getPublishableCommands()\\n- Init Hooks \\n - implement starting behavior for dependencies\\n - To enforce and type check this, use the `Initializable` type when making your Dependencies type!\\n- Emitter interface\\n - More generic interface to define any event emitter\\n - You can now swap out the SernEmitter with whatever emitter now. \\n```ts \\nclass DatabaseService implements Init {\\n //some hypothetical database\\n _pgsql : database() \\n\\n async init() {\\n await _pgsql.load()\\n }\\n\\n}\\n\\nawait makeDependencies({ \\n build: root => root.add({\\n db: new DatabaseService() //will be init\'ed automatically\\n })\\n})\\n\\n```\\n- new SernEmitter event `modulesLoaded` , which allows users to customize behavior after all modules are loaded!\\n```ts\\n\\nexport default eventModule({\\n name: \'modulesLoaded\',\\n type: EventType.Sern,\\n execute: () => {\\n console.log(\'All modules loaded\')\\n }\\n})\\n\\n\\n```\\n\\n#### Quality of Life\\n- faster module loading\\n - I utilize async generators for reading files now. A lot faster than the first iteration.\\n- better error handling\\n- Less boilerplate\\n - Services api cleans up v2 boilerplate\\n- class modules devex got upgraded and work better than before\\n- automatically ignore any files not ending in (mts, cts, mjs, cjs, ts, js)\\n - ignore commands and events with `!` prefix on filename or directory (ie: `!filename.ts` or `!directory` will be ignored by sern)\\n\\n- `Service` API (recommended to use this over useContainer hooks)\\n - Dependencies type must be globally augmented in order for Services api to function properly\\n- Less boilerplate\\n- new methods on ModuleManager\\n- automatically ignore any files not ending in (mts, cts, mjs, cjs, ts, js)\\n - ignore commands / events with `!` prefix on filename or directory (ie: `!filename.ts` or `!directory`)\\n- new SernEmitter event `modulesLoaded` , which allows users to customize behavior after all modules are loaded!\\n- Init Hooks \\n - implement starting behavior for dependencies\\n\\n### Experimental\\n- Experimental things may be subject to removal, need feedback and are not guaranteed stable\\n- dev / prod mode \\n - sern will behave differently depending on mode set\\n- init sern from `file` option\\n - reads from local sern.config.json\\n\\n```js \\nSern.init(\'file\'); \\n```\\n### Breaking changes\\n- Sern.makeDependencies -> makeDependencies\\n - it is asynchronous and top level function now. Make sure to await it before initing for proper synchronization.\\n- module store and manager internally changed, so those using them may recieve breaking changes\\n- BaseOptions type removed\\n\\n```diff\\n- Sern.makeDependencies({ build: () => {} })\\n+ await makeDependencies({ build: () => {} })\\n```\\n\\n### Deprecations\\n- Removed all previous marked deprecations in v3\\n- ModuleStore will be removed as a dependency in v4. The only way to access modules should be through ModuleManager\\n- Default Dependencies will be made internal in the v4. Users should only have access to its interface / contract"},{"id":"2.5.0","metadata":{"permalink":"/blog/2.5.0","editUrl":"https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/blog/2023-01-12-mdx-blog-post.md","source":"@site/blog/2023-01-12-mdx-blog-post.md","title":"Release 2.5.0","description":"2.5 Release","date":"2023-01-12T00:00:00.000Z","formattedDate":"January 12, 2023","tags":[{"label":"release","permalink":"/blog/tags/release"}],"readingTime":0.895,"hasTruncateMarker":false,"authors":[{"name":"jacoobes","title":"Head Dev","url":"https://github.com/jacoobes","imageURL":"https://github.com/jacoobes.png","key":"jacoobes"}],"frontMatter":{"slug":"2.5.0","title":"Release 2.5.0","authors":["jacoobes"],"tags":["release"]},"unlisted":false,"prevItem":{"title":"Release 3.0.0","permalink":"/blog/3.0.0"},"nextItem":{"title":"Release 2.0.0","permalink":"/blog/2.0.0"}},"content":"## 2.5 Release\\n\\n### Join our [discord](https://sern.dev/discord)
\\n- Thank you for using sern in your projects. It\'s only going to get better!\\n- I apologize for the sudden small breaking change. After this update, there won\'t be any for a while.\\nWow! We\'re increasing our semantic versioning by `+0.3.9`
\\nWhat does this mean?\\n### Breaking changes\\n- [controller](../docs/api/modules#controller) parameter for plugins has been removed\\n - You\'ll need to import it instead\\n - This **breaks** old [CommandPlugin](../docs/api/interfaces/CommandPlugin), but **not** old [EventPlugin](../docs/api/interfaces/EventPlugin)\\n### Deprecations\\n- [CommandPlugin](../docs/api/interfaces/CommandPlugin) and [EventPlugin](../docs/api/interfaces/EventPlugin) have been renamed [InitPlugin](../docs/api/interfaces/InitPlugin) and [ControlPlugin](../docs/api/interfaces/ControlPlugin)\\n\\n### Reason\\n- The naming of plugins was getting too complex. For example, plugin naming evolved into CommandModuleCommandPlugin, CommandModuleEventPlugin and more.\\n- I realize that this affects all plugins. I have updated all [plugins](https://github.com/sern-handler/awesome-plugins/pull/68) to match these changes\\n- The old way of declaring plugins has been deprecated in favor of newer functions that facilitate and ease typings\\n - [CommandControlPlugin](../docs/api/modules#commandcontrolplugin)\\n - [CommandInitPlugin](../docs/api/modules#commandinitplugin)\\n - [EventControlPlugin](../docs/api/modules#eventcontrolplugin)\\n - [EventInitPlugin](../docs/api/modules#eventinitplugin)\\n - [DiscordEventControlPlugin](../docs/api/modules#discordeventcontrolplugin)\\n This will probably be the last breaking change in a while. Thanks for using sern!"},{"id":"2.0.0","metadata":{"permalink":"/blog/2.0.0","editUrl":"https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/blog/2022-12-13-mdx-blog-post.md","source":"@site/blog/2022-12-13-mdx-blog-post.md","title":"Release 2.0.0","description":"2.0 Release","date":"2022-12-13T00:00:00.000Z","formattedDate":"December 13, 2022","tags":[{"label":"release","permalink":"/blog/tags/release"}],"readingTime":3.63,"hasTruncateMarker":false,"authors":[{"name":"jacoobes","title":"Head Dev","url":"https://github.com/jacoobes","imageURL":"https://github.com/jacoobes.png","key":"jacoobes"}],"frontMatter":{"slug":"2.0.0","title":"Release 2.0.0","authors":["jacoobes"],"tags":["release"]},"unlisted":false,"prevItem":{"title":"Release 2.5.0","permalink":"/blog/2.5.0"},"nextItem":{"title":"How to get started with sern!","permalink":"/blog/getting-started"}},"content":"## 2.0 Release\\nJoin our [discord](https://sern.dev/discord)!
\\nWow! We\'re finally increasing our semantic versioning by +`1.7.9.`
\\nWhat does this mean?\\n\\n### Plugin Support for Event Modules\\nYou can now use plugins for event modules. Previous version would throw an error if the \\n`plugins` field was populated.\\n\\n```typescript \\nexport function commandPlTest() : SernEmitterPlugin {\\n return {\\n type: PluginType.Command,\\n execute: ({ mod}, controller) => {\\n if(mod.name === \'module.register\') {\\n console.log(\'Event Module created correctly\')\\n return controller.next()\\n }\\n console.log(\'event name is wrong\')\\n return controller.stop()\\n }\\n }\\n}\\n```\\nApplying this plugin to some `eventModule`: \\n```typescript\\nexport default eventModule({\\n name: \'error\',\\n type: EventType.Sern,\\n plugins: [commandPlTest()],\\n execute(m) {\\n console.log(m)\\n },\\n})\\n```\\n## Dependency Injection and Decoupling\\n\\nThe powerful npm package `iti` decouples sern even more.\\nDecoupling data structures with the Inversion of Control pattern separates data from logic, which will help speed production\\nand make sern even more customizable than before.\\n\\n### How do I start?\\n```typescript title=\\"src/index.ts\\"\\n//With typescript, you can customize / augment your typings.\\ninterface MyDependencies extends Dependencies {\\n \'@sern/client\' : Singleton;\\n \'@sern/logger\' : Singleton \\n}\\n\\nexport const useContainer = Sern.makeDependencies ({\\n// exclude: new Set([\'@sern/logger\']), don\'t autofill optional dependencies\\n build: root => root\\n .add({ \'@sern/client\': single(client) }) \\n .add({ \'@sern/logger\': single(new DefaultLogging()) })\\n});\\n\\nSern.init({\\n defaultPrefix: \'!\', // removing defaultPrefix will shut down text commands\\n commands: \'src/commands\',\\n // events: \'src/events\' (optional),\\n containerConfig : {\\n get: useContainer //pass in your dependency getter here\\n }\\n});\\n\\n```\\nUsing the `Sern#makeDependencies` function, inject your dependencies. \\nWe\'ll use specific dependencies that are created with the `@sern/keyword`\\nkey.\\nUsing typescript to display all `keywords` and what they represent:\\n```typescript\\nexport interface Dependencies {\\n \'@sern/client\': Singleton ; //Discord Client\\n \'@sern/logger\'?: Singleton ; //Logger\\n \'@sern/emitter\': Singleton ; //SernEmitter\\n \'@sern/store\' : Singleton ; //Stores all Command Modules\\n \'@sern/modules\' : Singleton ; //Manages Modules\\n \'@sern/errors\': Singleton ; //A Lifetime / Crash Handler\\n}\\n```\\n:::danger\\nSern#addExternal has been deprecated and removed in favor of Sern#makeDependencies\\n:::\\nAt the moment, one optional dependency, `@sern/logger`, exists. If not added explicitly,\\nwe\'ll **autofill** with a [DefaultLogger](https://sern.dev/docs/api/classes/defaultlogging).\\n\\n:::tip\\nIf you don\'t want a logger, add it to the\\n`exclude` field while composing dependencies.\\n:::\\n\\nUse your generated dependency getter `useContainer` (use whatever name you want), access them\\nfrom anywhere.\\n:::note\\nthe function [useContainerRaw](https://sern.dev/docs/api/modules#usecontainerraw) is provided for direct access to dependencies and the internal\\ndata structure. Use this wisely as no guarantees are made and crashes can happen.\\n:::\\n\\nThe `build` field follows [createContainer](https://itijs.org/docs/quick-start#usage) function call.\\n\\n## New CommandTypes\\n2.0 includes all the new role select menus. `CommandType.MenuSelect` has been renamed into\\n`CommandType.StringSelect`. The remaining SelectMenus are\\n`CommandType.RoleSelect`, `CommandType.ChannelSelect`, `CommandType.UserSelect`, `CommandType.MentionableSelect`\\n```typescript title=\\"commands/roleselect.ts\\"\\nexport default commandModule({\\n type: CommandType.RoleSelect,\\n execute(ctx) {\\n ctx.reply(\'role select\')\\n },\\n})\\n```\\nIn addition, commandModules with ContextMenus have been renamed.\\n```diff\\n- CommandType.MenuUser, CommandType.MenuMsg \\n+ CommandType.CtxUser, CommandType.CtxMsg\\n```\\n## Typings Simplification\\nPre 2.0: \\n \\n
\\nPost 2.0:\\n
\\n\\n\\nCommandPlugin
and EventPlugin typings have also been static\'ified, transformed from types to interfaces\\n## Breaking Changes\\n \\n
\\nAll deprecation warnings from previous versions have taken effect, and are removed in 2.0.\\n\\n```diff\\n- type Module = EventModule | CommandModule\\n+ type AnyModule = EventModule | CommandModule\\n\\n-export type SpreadParamsunknown> = (\\n- args: Parameters [number],\\n- ) => unknown;\\n```\\nOverride type has been removed due to redundancy\\n```diff\\n- discord.js : 14.5\\n+ discord.js : 14.7\\n\\n-typescript: 4.7\\n+ typescript: 4.9\\n```\\n```diff\\n+ interface Wrapper {\\n+ readonly defaultPrefix?: string;\\n+ readonly commands: string;\\n+ readonly events?: string;\\n+ readonly containerConfig : {\\n+ get: (...keys: (keyof Dependencies)[]) => unknown[];\\n+ }\\n+}\\n\\n- interface Wrapper {\\n- readonly client: Client;\\n- readonly sernEmitter?: SernEmitter;\\n- readonly defaultPrefix?: string;\\n- readonly commands: string;\\n- readonly events?:\\n- | string\\n- | { mod: EventModule; absPath: string }[]\\n- | (() => { mod: EventModule; absPath: string }[]);\\n-}\\n```\\n```diff\\n+ DefaultLogger\\n+ DefaultModuleManager\\n+ SernEmitter\\n+ DefaultErrorHandling\\n+ type Singleton = () => T\\n+ type Transient = () => () => T; \\n+ type LogPayload = { message: T }\\n+ export const single = () => T\\n+ export const many = () => () => T\\n```\\nIncluding the previous section, some names to symbols and data structures were altered to\\nbe better represented. view [changelog](/404.html)\\n\\n## Context refactoring\\nThe context data structure has been internally altered to represent its dynamics better."},{"id":"getting-started","metadata":{"permalink":"/blog/getting-started","editUrl":"https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/blog/2022-09-30-mdx-blog-post.md","source":"@site/blog/2022-09-30-mdx-blog-post.md","title":"How to get started with sern!","description":"Hello everyone!","date":"2022-09-30T00:00:00.000Z","formattedDate":"September 30, 2022","tags":[{"label":"guides","permalink":"/blog/tags/guides"}],"readingTime":1.31,"hasTruncateMarker":false,"authors":[{"name":"Sr Izan","title":"Developer","url":"https://github.com/SrIzan10","imageURL":"https://github.com/SrIzan10.png","key":"Sr Izan"}],"frontMatter":{"slug":"getting-started","title":"How to get started with sern!","authors":["Sr Izan"],"tags":["guides"]},"unlisted":false,"prevItem":{"title":"Release 2.0.0","permalink":"/blog/2.0.0"},"nextItem":{"title":"Release 1.2.0","permalink":"/blog/1.2.0"}},"content":"## Hello everyone!\\n\\nI\'m Sr Izan, your fellow user and contributor.\\n\\nToday I\'m going to show you how to get started with sern and all its cool features.\\n\\n### Step 1: Install the CLI.\\n\\nInstall the CLI:\\n```\\nnpm i -g @sern/cli\\n```\\nand then run\\n```\\nsern init\\n```\\n:::tip\\nYou can also run `sern init -y` if you want to use the default options.\\n:::\\n\\nThe CLI is written in Typescript and open-sourced on [Github](https://github.com/sern-handler/cli). (thanks [evo](https://github.com/EvolutionX-10)!)\\n\\n### Step 2: Have some way to store secrets.\\n\\nNormally you\'d need a way to store secrets, and the best way to do that is by installing another package: `dotenv`\\n\\njust `npm i dotenv` in the project folder and add `require(\'dotenv\').config()` to your import section. Then, when you login, `process.env.TOKEN` (or however you have it named on your `.env` file) should do the trick.\\n\\n:::caution\\nIf you\'re using ESM, configure dotenv with `import \'dotenv/config\'` instead of `require(\'dotenv\').config()`.\\n:::\\n\\n### And... that\'s it?\\n\\nYes, that\'s it. Here\'s a little FAQ to get you started. You can also join the [Discord](https://sern.dev/discord) for any problems.\\n\\n### Extra: Video tutorial!\\n\\n\\n\\n## FAQ\\n\\n**Q**: How do I publish a slash command? \\n**A**: Install the publish extension. Little video: \\n\\n\\n**Q**: Any snippet VSCode extension? \\n**A**: Yeah, just search `sern Snippets` made by a verified publisher called Sr Izan (haha yeah me funny!) \\n\\n**Q**: HEEEELLLPPPP!!!! \\n**A**: Hey, don\'t panic! We\'re here to help so, join the [Discord](https://sern.dev/discord). We\'re trying to get to 100 members!"},{"id":"1.2.0","metadata":{"permalink":"/blog/1.2.0","editUrl":"https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/blog/2022-09-28-mdx-blog-post.md","source":"@site/blog/2022-09-28-mdx-blog-post.md","title":"Release 1.2.0","description":"Class-based modules","date":"2022-09-28T00:00:00.000Z","formattedDate":"September 28, 2022","tags":[{"label":"release","permalink":"/blog/tags/release"}],"readingTime":1.71,"hasTruncateMarker":false,"authors":[{"name":"jacoobes","title":"Head Dev","url":"https://github.com/jacoobes","imageURL":"https://github.com/jacoobes.png","key":"jacoobes"}],"frontMatter":{"slug":"1.2.0","title":"Release 1.2.0","authors":["jacoobes"],"tags":["release"]},"unlisted":false,"prevItem":{"title":"How to get started with sern!","permalink":"/blog/getting-started"}},"content":"## Class-based modules\\n\\nToday we\'re announcing the ability to create class based modules!\\nTo get started, install\\n```\\nnpm install @sern/handler@latest\\n```\\n\\nQuick List of changes!\\n- [Class based modules](#class-based-modules)\\n- [Deprecation Warnings](#deprecation-warnings)\\n- [Dependencies update](#dependencies-update)\\n\\n\\n### Class based modules\\nIncorporate class based modules into your project instead of the traditional `commandModule` or `eventModule`\\nExtend the new [CommandExecutable](docs/api/classes/CommandExecutable) or [EventExecutable](docs/api/classes/EventExecutable)\\n```ts title=\\"commands/meaning-of-life.ts\\"\\nimport { CommandType, CommandExecutable, type Args, type Context } from \'@sern/handler\';\\nimport { publish } from \'../plugins/publish.js\';\\nimport { serendipityOnly } from \'../plugins/serendipityOnly.js\';\\n\\nexport default class extends CommandExecutable {\\n type = CommandType.Both as const;\\n description = \'What is the meaning of life?\'\\n override onEvent = [\\n serendipityOnly()\\n ];\\n override plugins = [\\n publish(),\\n ];\\n // highlight-next-line\\n execute = async (ctx: Context, args: Args) => {\\n await ctx.reply(\'42\')\\n };\\n}\\n```\\n:::caution\\n\\nexecute must not be a method of the class. It should be as above, a property on the class!\\n\\n:::\\n\\n```ts title=\\"events/guildMemberAdd.ts\\"\\nimport { CommandType, EventExecutable, type EventType } from \'@sern/handler\';\\nimport type { GuildMember } from \'discord.js\'\\n\\nexport default class extends EventExecutable {\\n type = EventType.Discord as const;\\n // highlight-next-line\\n execute = (member: GuildMember) => {\\n console.log(member)\\n };\\n}\\n```\\nNow, you might ask **why** this feature was added.
Simply put, to give flexibility to the developers.\\nI believe that you should build your own structures however you might like and customize to your liking.\\nIn addition, **decorators now unofficially work with modules!**\\nFeel free to use TypeScript experimental decorators to augment and customize your classes. \\n\\n### Deprecation Warnings\\nThe next update will bring sern v2 with some important features. Here are some things to watch out for.\\n\\n- [Wrapper#client](docs/api/interfaces/Wrapper) will be deprecated\\n- [Wrapper#sernEmitter](docs/api/interfaces/Wrapper) will be deprecated\\n - a SernEmitter will be automatically created once Sern#init is called\\n- The option to pass in a function or array for [Wrapper#events](docs/api/interfaces/Wrapper) will be deprecated. Only strings are accepted.\\n- [Sern#addExternal](docs/api/classes/SernEmitter) will be deprecated in favor of a better way.\\n\\n### Dependencies Update\\n- TypeScript has been updated to 4.8.3\\n- Discord.js has been upgraded to 14.5"}]}')}}]); \ No newline at end of file diff --git a/assets/js/b654e1cf.5b8b0fa5.js b/assets/js/b654e1cf.5b8b0fa5.js deleted file mode 100644 index 47982facf..000000000 --- a/assets/js/b654e1cf.5b8b0fa5.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[5413],{9622:(A,g,e)=>{e.r(g),e.d(g,{assets:()=>C,contentTitle:()=>n,default:()=>I,frontMatter:()=>o,metadata:()=>t,toc:()=>E});var Q=e(4848),B=e(8453);const o={slug:"newlogo",title:"New logo!",authors:["sern"],tags:["branding"]},n="Why?",t={permalink:"/blog/newlogo",editUrl:"https://github.com/facebook/docusaurus/tree/main/packages/create-docusaurus/templates/shared/blog/2023-7-4-mdx-blog-post.md",source:"@site/blog/2023-7-4-mdx-blog-post.md",title:"New logo!",description:"Hey everyone! Today we have very special news for you all: We're changing our logo!",date:"2023-07-04T00:00:00.000Z",formattedDate:"July 4, 2023",tags:[{label:"branding",permalink:"/blog/tags/branding"}],readingTime:.83,hasTruncateMarker:!1,authors:[{name:"sern Team",url:"https://github.com/sern-handler",imageURL:"https://github.com/sernbot.png",key:"sern"}],frontMatter:{slug:"newlogo",title:"New logo!",authors:["sern"],tags:["branding"]},unlisted:!1,prevItem:{title:"Deploying sern with Railway",permalink:"/blog/railway-deploy"},nextItem:{title:"Release 3.0.0",permalink:"/blog/3.0.0"}},C={authorsImageUrls:[void 0]},E=[];function s(A){const g={a:"a",br:"br",code:"code",h1:"h1",img:"img",p:"p",...(0,B.R)(),...A.components};return(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)(g.p,{children:"Hey everyone! Today we have very special news for you all: We're changing our logo!"}),"\n",(0,Q.jsxs)(g.p,{children:["You see, on today's standards, having a simple logo is essential. Our logo aligns perfectly with these design principles but it can always be improved.",(0,Q.jsx)(g.br,{}),"\nWe were chilling, you know, cooking sern handler v3, sern gui, ",(0,Q.jsx)(g.code,{children:"npm create @sern/bot"})," and serncord when we thought about changing the logo to a sleek design with less colors.",(0,Q.jsx)(g.br,{}),"\nAnd here we are!"]}),"\n",(0,Q.jsx)(g.h1,{id:"who-did-our-new-branding",children:"Who did our new branding?"}),"\n",(0,Q.jsxs)(g.p,{children:[(0,Q.jsx)(g.a,{href:"https://github.com/Murtatrxx",children:"Ropox"}),"!",(0,Q.jsx)(g.br,{}),"\nBro's the GOAT. This website is maintained by him, the domain costs are funded by him and also he started brainstorming how the logo would be on paper:",(0,Q.jsx)(g.br,{}),"\n",(0,Q.jsx)(g.img,{src:e(1129).A+"",width:"3024",height:"4032"}),"\nAnd there it all clicked:",(0,Q.jsx)(g.br,{}),"\n",(0,Q.jsx)(g.img,{src:e(8165).A+"",width:"830",height:"455"}),"\nseren tried by the way!\n",(0,Q.jsx)(g.img,{src:e(8105).A+"",width:"908",height:"509"})]}),"\n",(0,Q.jsx)(g.h1,{id:"anyways-here-it-is",children:"Anyways, here it is:"}),"\n",(0,Q.jsx)(g.p,{children:(0,Q.jsx)(g.img,{src:e(3072).A+"",width:"1000",height:"1000"})}),"\n",(0,Q.jsx)(g.p,{children:"Pretty nice!"}),"\n",(0,Q.jsxs)(g.p,{children:["By the way, we have animations and variations on the way, so make sure to stay updated in the ",(0,Q.jsx)(g.a,{href:"https://sern.dev/discord",children:"discord server"}),"!"]}),"\n",(0,Q.jsx)(g.h1,{id:"finally-from-the-entire-sern-team-thank-you-for-sticking-around-\ufe0f",children:"Finally, from the entire sern team, thank you for sticking around \u2764\ufe0f"})]})}function I(A={}){const{wrapper:g}={...(0,B.R)(),...A.components};return g?(0,Q.jsx)(g,{...A,children:(0,Q.jsx)(s,{...A})}):s(A)}},8165:(A,g,e)=>{e.d(g,{A:()=>Q});const Q=e.p+"assets/images/paperlogo-41a5e76b2d3249b59105ee88f01f202b.png"},1129:(A,g,e)=>{e.d(g,{A:()=>Q});const Q=e.p+"assets/images/paperprototypes-cd697eaefd7ac467f2385dd119f6d78c.jpg"},8105:(A,g,e)=>{e.d(g,{A:()=>Q});const Q=e.p+"assets/images/serentried-2bcee1b2fda9864408e52072821d995f.png"},3072:(A,g,e)=>{e.d(g,{A:()=>Q});const Q="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAA+gAAAPoCAYAAABNo9TkAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAABYxSURBVHgB7d1NjlxXGYDhc+MgiJi0JRbQO8BZQcwKaK8gyQpwhjgD2wPbYkSyAswKaFaAvQL3EooxstxDEElfqtxGDBmB33vP80itKvW4VFVvfednDAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAD6qZQBM6u3Fi3UAAP8Xx/C4HmM9HJ9dHz+AD6fnN2N5/en4+9Xdy6fXAxDowLwEOgA0HKPkcPxQfrWO9c93xj9eCXZmJdCBaQl0AMh6eYr1X1w+uhwwEYEOTEugA0DbabK+jPXJ8dnru5e/PQzYuU8GAABA0PGX9PObsRyn6eMvxx/WnwzYORN0YFom6ACwLf+eqN+9fPTHATsk0IFpCXQA2KZjpF8uY/nGsnf2xhJ3AABgU9axXNyM9c27i+dfDtgRgQ4AAGzQcnban/724sXvB+yEJe7AtCxxB4B9WMZ6tYzlgSXvbJ0JOgAAsGnrWO6dTnp/d/HifMCGCXQAAGDzTleyiXS2TqADAAC7INLZOoEOAADshkhnywQ6AACwK7eRvv7p3cXjswEbItABAIDdOR0cdzN+9njAhgh0AABgrx6+vXj+cMBGCHQAAGDPHtuPzlYIdAAAYMeWs3WMPwzYAIEOAADs2jHQ77+7eP7lgDiBDgAA7N46lidOdadOoAMAALt3unrtZvz0NwPCBDoAADCLh6bolAl0AABgEsuZKTplAh0AAJiJe9HJEugAAMBElrO/Xby4PyBIoAMAAFO5M1bL3EkS6AAAwFRu70V3WBw9Ah0AAJjMcvbj8tkXA2IEOgAAMJ1lvbk/IEagAwAAE1ouBsQIdAAAYEbn9qFTI9ABAIAp2YdOjUAHAACmtKzjfECIQAcAACa13hsQItABAIAprcMEnRaBDgAATGkR6MQIdAAAAAgQ6AAAwKzOB4QIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA+G+WASHnn3+7DgBgSoc3z3w3Bab2yQAAAAA+OoEOAAAAAQIdAAAAAgQ6AAAABAh0AAAAGB+fQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdAAAAAgQ6AAAABAg0AEAACBAoAMAAECAQAcAAIAAgQ4AAAABAh0AAAACBDoAAAAECHQAAAAIEOgAAAAQINABAAAgQKADAABAgEAHAACAAIEOAAAAAQIdAAAAAgQ6AAAABAh0AAAACBDoAAAAECDQAQAAIECgAwAAQIBABwAAgACBDgAAAAECHQAAAAIEOgAAAAQIdGLWwwAAAJiQQAcAAIAAgU7MchgAAAATEui0rOMwAAAAJiTQiVmuBgAAwIQEOjV/HQAAABMS6MTceTUAAAAmJNBJOVw9vXbVGgAAMCOBTs+6XA4AAIDJCHSCltcDAABgMgKdoNM+9OV6AAAATESgk/N+H/p682oAAABMRKATtXw/AAAAJiLQSTpcPXtlmTsAADATgU7XevPdAAAAmIRAJ+wn35uiAwAAsxDoZH04LM4UHQAAmIJAJ+40RV8PAwAAYOcEOmm3U/TxdAAAAOycQCfvcPX85fHh1QAAANgxgc42rD987cA4AABgzwQ6m3C4+t1hrKul7gAAwG4JdDbjcPXsu7EOp7oDAAC7JNDZmE9PU/SrAQAAsDMCnU25PdX9hweuXgMAAPZGoLM5t/vRf/yVSAcAAPZEoLNJIh0AANgbgc5miXQAAGBPBDqb9p9Id3AcAACwbQKdzTtF+uHNs89dwQYAAGyZQGc3DlfPvhnr+vUYy/UAAADYGIHOrhyunr8c6z+P0/T1cgAAAGyIQGd33i95v3r+4Haa7gA5AABgG5YBO3d+79Hj4yv9q+PL/XwAAFmHN898NwWmZoLO7h2n6U/fn/Ruog4AAIT5lZLpnN/79tfHUL8Yy/LVAAAyTNCB2XkTZFrn9x6ejfHzL25jfdy3BB4APi6BDszOmyB88D7Yl89+Odbl/odYP/0d//fhEQD4nxLoAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACz+xe+xzYG5IBdhQAAAA5lWElmTU0AKgAAAAgAAAAAAAAA0lOTAAAAAElFTkSuQmCC"},8453:(A,g,e)=>{e.d(g,{R:()=>n,x:()=>t});var Q=e(6540);const B={},o=Q.createContext(B);function n(A){const g=Q.useContext(o);return Q.useMemo((function(){return"function"==typeof A?A(g):{...g,...A}}),[g,A])}function t(A){let g;return g=A.disableParentContext?"function"==typeof A.components?A.components(B):A.components||B:n(A.components),Q.createElement(o.Provider,{value:g},A.children)}}}]); \ No newline at end of file diff --git a/assets/js/b91ce718.910fbf3c.js b/assets/js/b91ce718.910fbf3c.js deleted file mode 100644 index d10eb0392..000000000 --- a/assets/js/b91ce718.910fbf3c.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[2407],{1150:(e,n,s)=>{s.r(n),s.d(n,{assets:()=>c,contentTitle:()=>l,default:()=>h,frontMatter:()=>t,metadata:()=>a,toc:()=>d});var i=s(4848),r=s(8453);const t={sidebar_position:6},l="Services",a={id:"guide/walkthrough/services",title:"Services",description:"This is version 3 api only!!",source:"@site/docs/guide/walkthrough/services.md",sourceDirName:"guide/walkthrough",slug:"/guide/walkthrough/services",permalink:"/docs/guide/walkthrough/services",draft:!1,unlisted:!1,editUrl:"https://github.com/sern-handler/website/edit/main/docs/guide/walkthrough/services.md",tags:[],version:"current",sidebarPosition:6,frontMatter:{sidebar_position:6},sidebar:"tutorialSidebar",previous:{title:"Plugins",permalink:"/docs/guide/walkthrough/plugins"},next:{title:"Autocomplete",permalink:"/docs/guide/walkthrough/autocomplete"}},c={},d=[{value:"Safety",id:"safety",level:2},{value:"Related api",id:"related-api",level:2}];function o(e){const n={a:"a",admonition:"admonition",blockquote:"blockquote",code:"code",h1:"h1",h2:"h2",li:"li",p:"p",pre:"pre",tabitem:"tabitem",tabs:"tabs",ul:"ul",...(0,r.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(n.h1,{id:"services",children:"Services"}),"\n",(0,i.jsx)(n.admonition,{type:"tip",children:(0,i.jsx)(n.p,{children:"This is version 3 api only!!"})}),"\n",(0,i.jsx)(n.admonition,{type:"tip",children:(0,i.jsx)(n.p,{children:"TLDR: The direct upgrade to useContainer. if you set up a bot with create-bot, check dependencies.d.ts.\nDependencies are the types that Services uses."})}),"\n",(0,i.jsx)(n.p,{children:"You need someway to use dependencies in your command module. Services to the rescue!"}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-ts",metastring:'title="src/dependencies.d.ts"',children:"import { CoreDependencies, Singleton } from '@sern/handler'\nimport { Client } from 'discord.js'\n\ninterface Dependencies extends CoreDependencies { \n '@sern/client': Singleton\n}\n\n"})}),"\n",(0,i.jsx)(n.p,{children:"Recall, some keys in Dependencies are special."}),"\n",(0,i.jsxs)(n.blockquote,{children:["\n",(0,i.jsx)(n.p,{children:"Special key dependency must implement its contracts."}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.code,{children:"@sern/client"}),": Your discord client. -> ",(0,i.jsx)(n.a,{href:"../../api/interfaces/Emitter",children:"Emitter"})]}),"\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.code,{children:"@sern/logger"}),": Log data -> ",(0,i.jsx)(n.a,{href:"../../api/interfaces/Logging",children:"Logging"})]}),"\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.code,{children:"@sern/errors"}),": Handling errors and lifetime -> ",(0,i.jsx)(n.a,{href:"../../api/interfaces/ErrorHandling",children:"ErrorHandling"})]}),"\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.code,{children:"@sern/modules"}),": Managing all command modules -> ",(0,i.jsx)(n.a,{href:"../../api/interfaces/ModuleManager",children:"ModuleManager"})]}),"\n",(0,i.jsxs)(n.li,{children:[(0,i.jsx)(n.code,{children:"@sern/emitter"}),": is the key to emit events and occurences in a project -> ",(0,i.jsx)(n.a,{href:"../../api/interfaces/Emitter",children:"Emitter"})]}),"\n"]}),"\n"]}),"\n",(0,i.jsx)(n.p,{children:"Lets try to access the client you provided."}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-ts",metastring:'title="src/commands/ping.ts"',children:"import { Service } from '@sern/handler'\n\nexport default commandModule({ \n // ...\n execute: (ctx) => {\n //Client!\n const client = Service('@sern/client');\n }\n // \n})\n"})}),"\n",(0,i.jsx)(n.p,{children:"import Tabs from '@theme/Tabs';\nimport TabItem from '@theme/TabItem';"}),"\n",(0,i.jsx)(n.h2,{id:"safety",children:"Safety"}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsx)(n.li,{children:"Services cannot be called in other services while makeDependencies is forming."}),"\n"]}),"\n",(0,i.jsxs)(n.tabs,{children:["\n",(0,i.jsxs)(n.tabitem,{value:"good",label:"A good example",children:["\n",(0,i.jsx)(n.p,{children:"Lets pass a logger into our database."}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-ts",metastring:'title="index.ts" showLineNumbers',children:"await makeDependencies({ \n build: root => root\n //Overriding the default logger provided.\n .upsert({ '@sern/logger': single(() => new Logger()) })\n\n // Wiring our logger into the database.\n .add(ctx => {\n return { database: single(() => new Database(ctx['sern/logger']))) }\n })\n})\n"})}),"\n"]}),"\n",(0,i.jsxs)(n.tabitem,{value:"bad",label:"Don't do this",children:["\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-ts",metastring:'title="index.ts" showLineNumbers',children:"await makeDependencies({ \n build: root => root\n //Overriding the default logger provided.\n .upsert({ '@sern/logger': single(() => new Logger()) })\n\n // Wiring our logger into the database.\n // We wire our database incorrectly. Logger should be passed INTO the constructor\n .add({ database: single(() => new Database()) })\n})\n"})}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-ts",metastring:'title="index.ts" showLineNumbers',children:"import { Service, makeDependencies } from '@sern/handler';\n\n//Calling Service prematurely!\nconst logger = Service('@sern/logger');\n\nclass Database {\n \n constructor() {\n this.logger = logger\n }\n}\n"})}),"\n",(0,i.jsx)(n.p,{children:"This is a code smell anyway. It breaks encapsulation and defeats the purpose of wiring dependencies\n\n"}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsxs)(n.li,{children:["\n",(0,i.jsx)(n.p,{children:"Services can only be used after sern has made dependencies."}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsx)(n.li,{children:"Calling a service before will crash your application."}),"\n"]}),"\n"]}),"\n",(0,i.jsxs)(n.li,{children:["\n",(0,i.jsx)(n.p,{children:"Services can be safely used outside of commandModules."}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsx)(n.li,{children:"Be careful to not cause too many side effects."}),"\n"]}),"\n"]}),"\n",(0,i.jsxs)(n.li,{children:["\n",(0,i.jsx)(n.p,{children:"You will need to wire dependencies together."}),"\n"]}),"\n"]}),"\n",(0,i.jsxs)(n.tabs,{children:["\n",(0,i.jsxs)(n.tabitem,{value:"good",label:"A good example",children:["\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-ts",metastring:'title="index.ts" showLineNumbers',children:"await makeDependencies(...pass your options here)\n"})}),"\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-ts",metastring:'title="commands/ping.ts" showLineNumbers',children:"// This is guaranteed to be defined if configured correctly\nimport { Service } from '@sern/handler';\nconst client = Service('@sern/client');\n"})}),"\n"]}),"\n",(0,i.jsxs)(n.tabitem,{value:"bad",label:"Don't do this",children:["\n",(0,i.jsx)(n.pre,{children:(0,i.jsx)(n.code,{className:"language-ts",metastring:'title="index.ts" showLineNumbers',children:"import { Service, makeDependencies } from '@sern/handler';\n/* DON'T USE SERVICES BEFORE CALLING makeDependencies */\nconst logger = Service('@sern/logger');\n\nawait makeDependencies()\n"})}),"\n"]}),"\n"]}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsxs)(n.li,{children:["Services can only be used after sern has made dependencies.\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsx)(n.li,{children:"Calling a service before will crash your application."}),"\n"]}),"\n"]}),"\n",(0,i.jsxs)(n.li,{children:["Services can be safely used outside of commandModules.\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsx)(n.li,{children:"Be careful to not cause too many side effects."}),"\n"]}),"\n"]}),"\n"]}),"\n",(0,i.jsx)(n.h2,{id:"related-api",children:"Related api"}),"\n",(0,i.jsxs)(n.ul,{children:["\n",(0,i.jsxs)(n.li,{children:["use ",(0,i.jsx)(n.code,{children:"Service"})," for single dependency."]}),"\n",(0,i.jsxs)(n.li,{children:["use ",(0,i.jsx)(n.code,{children:"Services"})," for multiple dependencies."]}),"\n"]})]})]})]})}function h(e={}){const{wrapper:n}={...(0,r.R)(),...e.components};return n?(0,i.jsx)(n,{...e,children:(0,i.jsx)(o,{...e})}):o(e)}},8453:(e,n,s)=>{s.d(n,{R:()=>l,x:()=>a});var i=s(6540);const r={},t=i.createContext(r);function l(e){const n=i.useContext(t);return i.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function a(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(r):e.components||r:l(e.components),i.createElement(t.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/bcd9df7e.45ba7d7b.js b/assets/js/bcd9df7e.45ba7d7b.js deleted file mode 100644 index 0b56637cc..000000000 --- a/assets/js/bcd9df7e.45ba7d7b.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[4793],{4837:(e,n,r)=>{r.r(n),r.d(n,{assets:()=>t,contentTitle:()=>l,default:()=>x,frontMatter:()=>i,metadata:()=>c,toc:()=>h});var s=r(4848),d=r(8453);const i={id:"Context",title:"Class: Context",sidebar_label:"Context",sidebar_position:0,custom_edit_url:null},l=void 0,c={id:"api/classes/Context",title:"Class: Context",description:"Since",source:"@site/docs/api/classes/Context.md",sourceDirName:"api/classes",slug:"/api/classes/Context",permalink:"/docs/api/classes/Context",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"Context",title:"Class: Context",sidebar_label:"Context",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"CommandExecutable",permalink:"/docs/api/classes/CommandExecutable"},next:{title:"DefaultErrorHandling",permalink:"/docs/api/classes/DefaultErrorHandling"}},t={},h=[{value:"Hierarchy",id:"hierarchy",level:2},{value:"Constructors",id:"constructors",level:2},{value:"constructor",id:"constructor",level:3},{value:"Parameters",id:"parameters",level:4},{value:"Returns",id:"returns",level:4},{value:"Overrides",id:"overrides",level:4},{value:"Defined in",id:"defined-in",level:4},{value:"Properties",id:"properties",level:2},{value:"ctx",id:"ctx",level:3},{value:"Inherited from",id:"inherited-from",level:4},{value:"Defined in",id:"defined-in-1",level:4},{value:"Accessors",id:"accessors",level:2},{value:"channel",id:"channel",level:3},{value:"Returns",id:"returns-1",level:4},{value:"Defined in",id:"defined-in-2",level:4},{value:"channelId",id:"channelid",level:3},{value:"Returns",id:"returns-2",level:4},{value:"Defined in",id:"defined-in-3",level:4},{value:"client",id:"client",level:3},{value:"Returns",id:"returns-3",level:4},{value:"Defined in",id:"defined-in-4",level:4},{value:"createdTimestamp",id:"createdtimestamp",level:3},{value:"Returns",id:"returns-4",level:4},{value:"Defined in",id:"defined-in-5",level:4},{value:"guild",id:"guild",level:3},{value:"Returns",id:"returns-5",level:4},{value:"Defined in",id:"defined-in-6",level:4},{value:"guildId",id:"guildid",level:3},{value:"Returns",id:"returns-6",level:4},{value:"Defined in",id:"defined-in-7",level:4},{value:"id",id:"id",level:3},{value:"Returns",id:"returns-7",level:4},{value:"Defined in",id:"defined-in-8",level:4},{value:"inGuild",id:"inguild",level:3},{value:"Returns",id:"returns-8",level:4},{value:"Defined in",id:"defined-in-9",level:4},{value:"interaction",id:"interaction",level:3},{value:"Returns",id:"returns-9",level:4},{value:"Inherited from",id:"inherited-from-1",level:4},{value:"Defined in",id:"defined-in-10",level:4},{value:"member",id:"member",level:3},{value:"Returns",id:"returns-10",level:4},{value:"Defined in",id:"defined-in-11",level:4},{value:"message",id:"message",level:3},{value:"Returns",id:"returns-11",level:4},{value:"Inherited from",id:"inherited-from-2",level:4},{value:"Defined in",id:"defined-in-12",level:4},{value:"options",id:"options",level:3},{value:"Returns",id:"returns-12",level:4},{value:"Overrides",id:"overrides-1",level:4},{value:"Defined in",id:"defined-in-13",level:4},{value:"user",id:"user",level:3},{value:"Returns",id:"returns-13",level:4},{value:"Defined in",id:"defined-in-14",level:4},{value:"userId",id:"userid",level:3},{value:"Returns",id:"returns-14",level:4},{value:"Defined in",id:"defined-in-15",level:4},{value:"Methods",id:"methods",level:2},{value:"isMessage",id:"ismessage",level:3},{value:"Returns",id:"returns-15",level:4},{value:"Inherited from",id:"inherited-from-3",level:4},{value:"Defined in",id:"defined-in-16",level:4},{value:"isSlash",id:"isslash",level:3},{value:"Returns",id:"returns-16",level:4},{value:"Inherited from",id:"inherited-from-4",level:4},{value:"Defined in",id:"defined-in-17",level:4},{value:"reply",id:"reply",level:3},{value:"Parameters",id:"parameters-1",level:4},{value:"Returns",id:"returns-17",level:4},{value:"Defined in",id:"defined-in-18",level:4},{value:"wrap",id:"wrap",level:3},{value:"Parameters",id:"parameters-2",level:4},{value:"Returns",id:"returns-18",level:4},{value:"Overrides",id:"overrides-2",level:4},{value:"Defined in",id:"defined-in-19",level:4}];function o(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",hr:"hr",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,d.R)(),...e.components};return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(n.p,{children:(0,s.jsx)(n.strong,{children:(0,s.jsx)(n.code,{children:"Since"})})}),"\n",(0,s.jsx)(n.p,{children:"1.0.0\nProvides values shared between\nMessage and ChatInputCommandInteraction"}),"\n",(0,s.jsx)(n.h2,{id:"hierarchy",children:"Hierarchy"}),"\n",(0,s.jsxs)(n.ul,{children:["\n",(0,s.jsxs)(n.li,{children:["\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"CoreContext"}),"<",(0,s.jsx)(n.code,{children:"Message"}),", ",(0,s.jsx)(n.code,{children:"ChatInputCommandInteraction"}),">"]}),"\n",(0,s.jsxs)(n.p,{children:["\u21b3 ",(0,s.jsx)(n.strong,{children:(0,s.jsx)(n.code,{children:"Context"})})]}),"\n"]}),"\n"]}),"\n",(0,s.jsx)(n.h2,{id:"constructors",children:"Constructors"}),"\n",(0,s.jsx)(n.h3,{id:"constructor",children:"constructor"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.strong,{children:"new Context"}),"(",(0,s.jsx)(n.code,{children:"ctx"}),"): ",(0,s.jsx)(n.a,{href:"/docs/api/classes/Context",children:(0,s.jsx)(n.code,{children:"Context"})})]}),"\n",(0,s.jsx)(n.h4,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,s.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,s.jsx)(n.tbody,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{style:{textAlign:"left"},children:(0,s.jsx)(n.code,{children:"ctx"})}),(0,s.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,s.jsx)(n.code,{children:"Result"}),"<",(0,s.jsx)(n.code,{children:"Message"}),"<",(0,s.jsx)(n.code,{children:"boolean"}),">, ",(0,s.jsx)(n.code,{children:"ChatInputCommandInteraction"}),"<",(0,s.jsx)(n.code,{children:"CacheType"}),">>"]})]})})]}),"\n",(0,s.jsx)(n.h4,{id:"returns",children:"Returns"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"/docs/api/classes/Context",children:(0,s.jsx)(n.code,{children:"Context"})})}),"\n",(0,s.jsx)(n.h4,{id:"overrides",children:"Overrides"}),"\n",(0,s.jsx)(n.p,{children:"CoreContext<Message, ChatInputCommandInteraction>.constructor"}),"\n",(0,s.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L29",children:"src/core/structures/context.ts:29"})}),"\n",(0,s.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,s.jsx)(n.h3,{id:"ctx",children:"ctx"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"Protected"})," ",(0,s.jsx)(n.strong,{children:"ctx"}),": ",(0,s.jsx)(n.code,{children:"Result"}),"<",(0,s.jsx)(n.code,{children:"Message"}),"<",(0,s.jsx)(n.code,{children:"boolean"}),">, ",(0,s.jsx)(n.code,{children:"ChatInputCommandInteraction"}),"<",(0,s.jsx)(n.code,{children:"CacheType"}),">>"]}),"\n",(0,s.jsx)(n.h4,{id:"inherited-from",children:"Inherited from"}),"\n",(0,s.jsx)(n.p,{children:"CoreContext.ctx"}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L29",children:"src/core/structures/context.ts:29"})}),"\n",(0,s.jsx)(n.h2,{id:"accessors",children:"Accessors"}),"\n",(0,s.jsx)(n.h3,{id:"channel",children:"channel"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"get"})," ",(0,s.jsx)(n.strong,{children:"channel"}),"(): ",(0,s.jsx)(n.code,{children:"null"})," | ",(0,s.jsx)(n.code,{children:"TextBasedChannel"})]}),"\n",(0,s.jsx)(n.h4,{id:"returns-1",children:"Returns"}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"null"})," | ",(0,s.jsx)(n.code,{children:"TextBasedChannel"})]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L39",children:"src/core/structures/context.ts:39"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"channelid",children:"channelId"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"get"})," ",(0,s.jsx)(n.strong,{children:"channelId"}),"(): ",(0,s.jsx)(n.code,{children:"string"})]}),"\n",(0,s.jsx)(n.h4,{id:"returns-2",children:"Returns"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.code,{children:"string"})}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L45",children:"src/core/structures/context.ts:45"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"client",children:"client"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"get"})," ",(0,s.jsx)(n.strong,{children:"client"}),"(): ",(0,s.jsx)(n.code,{children:"Client"}),"<",(0,s.jsx)(n.code,{children:"boolean"}),">"]}),"\n",(0,s.jsx)(n.h4,{id:"returns-3",children:"Returns"}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"Client"}),"<",(0,s.jsx)(n.code,{children:"boolean"}),">"]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-4",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L91",children:"src/core/structures/context.ts:91"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"createdtimestamp",children:"createdTimestamp"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"get"})," ",(0,s.jsx)(n.strong,{children:"createdTimestamp"}),"(): ",(0,s.jsx)(n.code,{children:"number"})]}),"\n",(0,s.jsx)(n.h4,{id:"returns-4",children:"Returns"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.code,{children:"number"})}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-5",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L65",children:"src/core/structures/context.ts:65"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"guild",children:"guild"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"get"})," ",(0,s.jsx)(n.strong,{children:"guild"}),"(): ",(0,s.jsx)(n.code,{children:"null"})," | ",(0,s.jsx)(n.code,{children:"Guild"})]}),"\n",(0,s.jsx)(n.h4,{id:"returns-5",children:"Returns"}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"null"})," | ",(0,s.jsx)(n.code,{children:"Guild"})]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-6",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L71",children:"src/core/structures/context.ts:71"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"guildid",children:"guildId"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"get"})," ",(0,s.jsx)(n.strong,{children:"guildId"}),"(): ",(0,s.jsx)(n.code,{children:"null"})," | ",(0,s.jsx)(n.code,{children:"string"})]}),"\n",(0,s.jsx)(n.h4,{id:"returns-6",children:"Returns"}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"null"})," | ",(0,s.jsx)(n.code,{children:"string"})]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-7",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L77",children:"src/core/structures/context.ts:77"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"id",children:"id"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"get"})," ",(0,s.jsx)(n.strong,{children:"id"}),"(): ",(0,s.jsx)(n.code,{children:"string"})]}),"\n",(0,s.jsx)(n.h4,{id:"returns-7",children:"Returns"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.code,{children:"string"})}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-8",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L33",children:"src/core/structures/context.ts:33"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"inguild",children:"inGuild"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"get"})," ",(0,s.jsx)(n.strong,{children:"inGuild"}),"(): ",(0,s.jsx)(n.code,{children:"boolean"})]}),"\n",(0,s.jsx)(n.h4,{id:"returns-8",children:"Returns"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.code,{children:"boolean"})}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-9",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L97",children:"src/core/structures/context.ts:97"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"interaction",children:"interaction"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"get"})," ",(0,s.jsx)(n.strong,{children:"interaction"}),"(): ",(0,s.jsx)(n.code,{children:"I"})]}),"\n",(0,s.jsx)(n.h4,{id:"returns-9",children:"Returns"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.code,{children:"I"})}),"\n",(0,s.jsx)(n.h4,{id:"inherited-from-1",children:"Inherited from"}),"\n",(0,s.jsx)(n.p,{children:"CoreContext.interaction"}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-10",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/core-context.ts#L15",children:"src/core/structures/core-context.ts:15"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"member",children:"member"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"get"})," ",(0,s.jsx)(n.strong,{children:"member"}),"(): ",(0,s.jsx)(n.code,{children:"null"})," | ",(0,s.jsx)(n.code,{children:"GuildMember"})," | ",(0,s.jsx)(n.code,{children:"APIInteractionGuildMember"})]}),"\n",(0,s.jsx)(n.h4,{id:"returns-10",children:"Returns"}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"null"})," | ",(0,s.jsx)(n.code,{children:"GuildMember"})," | ",(0,s.jsx)(n.code,{children:"APIInteractionGuildMember"})]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-11",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L85",children:"src/core/structures/context.ts:85"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"message",children:"message"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"get"})," ",(0,s.jsx)(n.strong,{children:"message"}),"(): ",(0,s.jsx)(n.code,{children:"M"})]}),"\n",(0,s.jsx)(n.h4,{id:"returns-11",children:"Returns"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.code,{children:"M"})}),"\n",(0,s.jsx)(n.h4,{id:"inherited-from-2",children:"Inherited from"}),"\n",(0,s.jsx)(n.p,{children:"CoreContext.message"}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-12",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/core-context.ts#L12",children:"src/core/structures/core-context.ts:12"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"options",children:"options"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"get"})," ",(0,s.jsx)(n.strong,{children:"options"}),"(): ",(0,s.jsx)(n.code,{children:"Omit"}),"<",(0,s.jsx)(n.code,{children:"CommandInteractionOptionResolver"}),"<",(0,s.jsx)(n.code,{children:"CacheType"}),">, ",(0,s.jsx)(n.code,{children:'"getMessage"'})," | ",(0,s.jsx)(n.code,{children:'"getFocused"'}),">"]}),"\n",(0,s.jsx)(n.h4,{id:"returns-12",children:"Returns"}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"Omit"}),"<",(0,s.jsx)(n.code,{children:"CommandInteractionOptionResolver"}),"<",(0,s.jsx)(n.code,{children:"CacheType"}),">, ",(0,s.jsx)(n.code,{children:'"getMessage"'})," | ",(0,s.jsx)(n.code,{children:'"getFocused"'}),">"]}),"\n",(0,s.jsx)(n.h4,{id:"overrides-1",children:"Overrides"}),"\n",(0,s.jsx)(n.p,{children:"CoreContext.options"}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-13",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L26",children:"src/core/structures/context.ts:26"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"user",children:"user"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"get"})," ",(0,s.jsx)(n.strong,{children:"user"}),"(): ",(0,s.jsx)(n.code,{children:"User"})]}),"\n",(0,s.jsx)(n.p,{children:"If context is holding a message, message.author\nelse, interaction.user"}),"\n",(0,s.jsx)(n.h4,{id:"returns-13",children:"Returns"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.code,{children:"User"})}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-14",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L55",children:"src/core/structures/context.ts:55"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"userid",children:"userId"}),"\n",(0,s.jsxs)(n.p,{children:["\u2022 ",(0,s.jsx)(n.code,{children:"get"})," ",(0,s.jsx)(n.strong,{children:"userId"}),"(): ",(0,s.jsx)(n.code,{children:"string"})]}),"\n",(0,s.jsx)(n.h4,{id:"returns-14",children:"Returns"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.code,{children:"string"})}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-15",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L61",children:"src/core/structures/context.ts:61"})}),"\n",(0,s.jsx)(n.h2,{id:"methods",children:"Methods"}),"\n",(0,s.jsx)(n.h3,{id:"ismessage",children:"isMessage"}),"\n",(0,s.jsxs)(n.p,{children:["\u25b8 ",(0,s.jsx)(n.strong,{children:"isMessage"}),"(): this is CoreContext , never>"]}),"\n",(0,s.jsx)(n.h4,{id:"returns-15",children:"Returns"}),"\n",(0,s.jsx)(n.p,{children:"this is CoreContext , never>"}),"\n",(0,s.jsx)(n.h4,{id:"inherited-from-3",children:"Inherited from"}),"\n",(0,s.jsx)(n.p,{children:"CoreContext.isMessage"}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-16",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/core-context.ts#L19",children:"src/core/structures/core-context.ts:19"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"isslash",children:"isSlash"}),"\n",(0,s.jsxs)(n.p,{children:["\u25b8 ",(0,s.jsx)(n.strong,{children:"isSlash"}),"(): this is CoreContext >"]}),"\n",(0,s.jsx)(n.h4,{id:"returns-16",children:"Returns"}),"\n",(0,s.jsx)(n.p,{children:"this is CoreContext >"}),"\n",(0,s.jsx)(n.h4,{id:"inherited-from-4",children:"Inherited from"}),"\n",(0,s.jsx)(n.p,{children:"CoreContext.isSlash"}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-17",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/core-context.ts#L23",children:"src/core/structures/core-context.ts:23"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"reply",children:"reply"}),"\n",(0,s.jsxs)(n.p,{children:["\u25b8 ",(0,s.jsx)(n.strong,{children:"reply"}),"(",(0,s.jsx)(n.code,{children:"content"}),"): ",(0,s.jsx)(n.code,{children:"Promise"}),"<",(0,s.jsx)(n.code,{children:"Message"}),"<",(0,s.jsx)(n.code,{children:"boolean"}),">>"]}),"\n",(0,s.jsx)(n.h4,{id:"parameters-1",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,s.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,s.jsx)(n.tbody,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{style:{textAlign:"left"},children:(0,s.jsx)(n.code,{children:"content"})}),(0,s.jsx)(n.td,{style:{textAlign:"left"},children:(0,s.jsx)(n.code,{children:"ReplyOptions"})})]})})]}),"\n",(0,s.jsx)(n.h4,{id:"returns-17",children:"Returns"}),"\n",(0,s.jsxs)(n.p,{children:[(0,s.jsx)(n.code,{children:"Promise"}),"<",(0,s.jsx)(n.code,{children:"Message"}),"<",(0,s.jsx)(n.code,{children:"boolean"}),">>"]}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-18",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L103",children:"src/core/structures/context.ts:103"})}),"\n",(0,s.jsx)(n.hr,{}),"\n",(0,s.jsx)(n.h3,{id:"wrap",children:"wrap"}),"\n",(0,s.jsxs)(n.p,{children:["\u25b8 ",(0,s.jsx)(n.strong,{children:"wrap"}),"(",(0,s.jsx)(n.code,{children:"wrappable"}),"): ",(0,s.jsx)(n.a,{href:"/docs/api/classes/Context",children:(0,s.jsx)(n.code,{children:"Context"})})]}),"\n",(0,s.jsx)(n.h4,{id:"parameters-2",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,s.jsxs)(n.table,{children:[(0,s.jsx)(n.thead,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,s.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,s.jsx)(n.tbody,{children:(0,s.jsxs)(n.tr,{children:[(0,s.jsx)(n.td,{style:{textAlign:"left"},children:(0,s.jsx)(n.code,{children:"wrappable"})}),(0,s.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,s.jsx)(n.code,{children:"Message"}),"<",(0,s.jsx)(n.code,{children:"boolean"}),"> | ",(0,s.jsx)(n.code,{children:"BaseInteraction"}),"<",(0,s.jsx)(n.code,{children:"CacheType"}),">"]})]})})]}),"\n",(0,s.jsx)(n.h4,{id:"returns-18",children:"Returns"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"/docs/api/classes/Context",children:(0,s.jsx)(n.code,{children:"Context"})})}),"\n",(0,s.jsx)(n.h4,{id:"overrides-2",children:"Overrides"}),"\n",(0,s.jsx)(n.p,{children:"CoreContext.wrap"}),"\n",(0,s.jsx)(n.h4,{id:"defined-in-19",children:"Defined in"}),"\n",(0,s.jsx)(n.p,{children:(0,s.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/91b3768e376cfe22ec37d8ab44f4e4a4dfe8a1e8/src/core/structures/context.ts#L113",children:"src/core/structures/context.ts:113"})})]})}function x(e={}){const{wrapper:n}={...(0,d.R)(),...e.components};return n?(0,s.jsx)(n,{...e,children:(0,s.jsx)(o,{...e})}):o(e)}},8453:(e,n,r)=>{r.d(n,{R:()=>l,x:()=>c});var s=r(6540);const d={},i=s.createContext(d);function l(e){const n=s.useContext(i);return s.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function c(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(d):e.components||d:l(e.components),s.createElement(i.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/beef0c9d.bf88ad5a.js b/assets/js/beef0c9d.bf88ad5a.js deleted file mode 100644 index c1ea45bd4..000000000 --- a/assets/js/beef0c9d.bf88ad5a.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[497],{9898:(e,n,r)=>{r.r(n),r.d(n,{assets:()=>o,contentTitle:()=>t,default:()=>u,frontMatter:()=>d,metadata:()=>l,toc:()=>c});var i=r(4848),s=r(8453);const d={id:"SernError",title:"Enumeration: SernError",sidebar_label:"SernError",sidebar_position:0,custom_edit_url:null},t=void 0,l={id:"api/enums/SernError",title:"Enumeration: SernError",description:"Enumeration Members",source:"@site/docs/api/enums/SernError.md",sourceDirName:"api/enums",slug:"/api/enums/SernError",permalink:"/docs/api/enums/SernError",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"SernError",title:"Enumeration: SernError",sidebar_label:"SernError",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"PluginType",permalink:"/docs/api/enums/PluginType"},next:{title:"CommandExecutable",permalink:"/docs/api/classes/CommandExecutable"}},o={},c=[{value:"Enumeration Members",id:"enumeration-members",level:2},{value:"InvalidModuleType",id:"invalidmoduletype",level:3},{value:"Defined in",id:"defined-in",level:4},{value:"MismatchEvent",id:"mismatchevent",level:3},{value:"Defined in",id:"defined-in-1",level:4},{value:"MismatchModule",id:"mismatchmodule",level:3},{value:"Defined in",id:"defined-in-2",level:4},{value:"MissingRequired",id:"missingrequired",level:3},{value:"Defined in",id:"defined-in-3",level:4},{value:"NotSupportedInteraction",id:"notsupportedinteraction",level:3},{value:"Defined in",id:"defined-in-4",level:4},{value:"NotSupportedYet",id:"notsupportedyet",level:3},{value:"Defined in",id:"defined-in-5",level:4},{value:"PluginFailure",id:"pluginfailure",level:3},{value:"Defined in",id:"defined-in-6",level:4},{value:"UndefinedModule",id:"undefinedmodule",level:3},{value:"Defined in",id:"defined-in-7",level:4}];function h(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",hr:"hr",p:"p",strong:"strong",...(0,s.R)(),...e.components};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(n.h2,{id:"enumeration-members",children:"Enumeration Members"}),"\n",(0,i.jsx)(n.h3,{id:"invalidmoduletype",children:"InvalidModuleType"}),"\n",(0,i.jsxs)(n.p,{children:["\u2022 ",(0,i.jsx)(n.strong,{children:"InvalidModuleType"})," = ",(0,i.jsx)(n.code,{children:'"Detected an unknown module type"'})]}),"\n",(0,i.jsx)(n.p,{children:"Throws when registering an invalid module.\nThis means it is undefined or an invalid command type was provided"}),"\n",(0,i.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/handler/structures/errors.ts#L9",children:"src/handler/structures/errors.ts:9"})}),"\n",(0,i.jsx)(n.hr,{}),"\n",(0,i.jsx)(n.h3,{id:"mismatchevent",children:"MismatchEvent"}),"\n",(0,i.jsxs)(n.p,{children:["\u2022 ",(0,i.jsx)(n.strong,{children:"MismatchEvent"})," = ",(0,i.jsx)(n.code,{children:'"You cannot use message when an interaction fired or vice versa"'})]}),"\n",(0,i.jsx)(n.p,{children:"A crash that occurs when accessing an invalid property of Context"}),"\n",(0,i.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/handler/structures/errors.ts#L29",children:"src/handler/structures/errors.ts:29"})}),"\n",(0,i.jsx)(n.hr,{}),"\n",(0,i.jsx)(n.h3,{id:"mismatchmodule",children:"MismatchModule"}),"\n",(0,i.jsxs)(n.p,{children:["\u2022 ",(0,i.jsx)(n.strong,{children:"MismatchModule"})," = ",(0,i.jsx)(n.code,{children:'"A module type mismatched with event emitted!"'})]}),"\n",(0,i.jsx)(n.p,{children:"Attempted to lookup module in command module store. Nothing was found!"}),"\n",(0,i.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/handler/structures/errors.ts#L17",children:"src/handler/structures/errors.ts:17"})}),"\n",(0,i.jsx)(n.hr,{}),"\n",(0,i.jsx)(n.h3,{id:"missingrequired",children:"MissingRequired"}),"\n",(0,i.jsxs)(n.p,{children:["\u2022 ",(0,i.jsx)(n.strong,{children:"MissingRequired"})," = ",(0,i.jsx)(n.code,{children:'"@sern/client is required but was not found"'})]}),"\n",(0,i.jsx)(n.p,{children:"Required Dependency not found"}),"\n",(0,i.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/handler/structures/errors.ts#L37",children:"src/handler/structures/errors.ts:37"})}),"\n",(0,i.jsx)(n.hr,{}),"\n",(0,i.jsx)(n.h3,{id:"notsupportedinteraction",children:"NotSupportedInteraction"}),"\n",(0,i.jsxs)(n.p,{children:["\u2022 ",(0,i.jsx)(n.strong,{children:"NotSupportedInteraction"})," = ",(0,i.jsx)(n.code,{children:'"This interaction is not supported."'})]}),"\n",(0,i.jsx)(n.p,{children:"Unsupported interaction at this moment."}),"\n",(0,i.jsx)(n.h4,{id:"defined-in-4",children:"Defined in"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/handler/structures/errors.ts#L21",children:"src/handler/structures/errors.ts:21"})}),"\n",(0,i.jsx)(n.hr,{}),"\n",(0,i.jsx)(n.h3,{id:"notsupportedyet",children:"NotSupportedYet"}),"\n",(0,i.jsxs)(n.p,{children:["\u2022 ",(0,i.jsx)(n.strong,{children:"NotSupportedYet"})," = ",(0,i.jsx)(n.code,{children:'"This feature is not supported yet"'})]}),"\n",(0,i.jsx)(n.p,{children:"Unsupported feature attempted to access at this time"}),"\n",(0,i.jsx)(n.h4,{id:"defined-in-5",children:"Defined in"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/handler/structures/errors.ts#L33",children:"src/handler/structures/errors.ts:33"})}),"\n",(0,i.jsx)(n.hr,{}),"\n",(0,i.jsx)(n.h3,{id:"pluginfailure",children:"PluginFailure"}),"\n",(0,i.jsxs)(n.p,{children:["\u2022 ",(0,i.jsx)(n.strong,{children:"PluginFailure"})," = ",(0,i.jsx)(n.code,{children:'"A plugin failed to call controller.next()"'})]}),"\n",(0,i.jsxs)(n.p,{children:["One plugin called ",(0,i.jsx)(n.code,{children:"controller.stop()"})," (end command execution / loading)"]}),"\n",(0,i.jsx)(n.h4,{id:"defined-in-6",children:"Defined in"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/handler/structures/errors.ts#L25",children:"src/handler/structures/errors.ts:25"})}),"\n",(0,i.jsx)(n.hr,{}),"\n",(0,i.jsx)(n.h3,{id:"undefinedmodule",children:"UndefinedModule"}),"\n",(0,i.jsxs)(n.p,{children:["\u2022 ",(0,i.jsx)(n.strong,{children:"UndefinedModule"})," = ",(0,i.jsx)(n.code,{children:'"A module could not be detected"'})]}),"\n",(0,i.jsx)(n.p,{children:"Attempted to lookup module in command module store. Nothing was found!"}),"\n",(0,i.jsx)(n.h4,{id:"defined-in-7",children:"Defined in"}),"\n",(0,i.jsx)(n.p,{children:(0,i.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/c1f6906/src/handler/structures/errors.ts#L13",children:"src/handler/structures/errors.ts:13"})})]})}function u(e={}){const{wrapper:n}={...(0,s.R)(),...e.components};return n?(0,i.jsx)(n,{...e,children:(0,i.jsx)(h,{...e})}):h(e)}},8453:(e,n,r)=>{r.d(n,{R:()=>t,x:()=>l});var i=r(6540);const s={},d=i.createContext(s);function t(e){const n=i.useContext(d);return i.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function l(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:t(e.components),i.createElement(d.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/c0846785.305a360d.js b/assets/js/c0846785.305a360d.js deleted file mode 100644 index 14d8b690d..000000000 --- a/assets/js/c0846785.305a360d.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[7318],{9350:(e,n,s)=>{s.r(n),s.d(n,{assets:()=>c,contentTitle:()=>d,default:()=>o,frontMatter:()=>r,metadata:()=>i,toc:()=>h});var t=s(4848),l=s(8453);const r={id:"EventExecutable",title:"Class: EventExecutable ",sidebar_label:"EventExecutable",sidebar_position:0,custom_edit_url:null},d=void 0,i={id:"api/classes/EventExecutable",title:"Class: EventExecutable ",description:"Deprecated",source:"@site/docs/api/classes/EventExecutable.md",sourceDirName:"api/classes",slug:"/api/classes/EventExecutable",permalink:"/docs/api/classes/EventExecutable",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"EventExecutable",title:"Class: EventExecutable ",sidebar_label:"EventExecutable",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"DefaultModuleManager",permalink:"/docs/api/classes/DefaultModuleManager"},next:{title:"ModuleStore",permalink:"/docs/api/classes/ModuleStore"}},c={},h=[{value:"Type parameters",id:"type-parameters",level:2},{value:"Constructors",id:"constructors",level:2},{value:"constructor",id:"constructor",level:3},{value:"Type parameters",id:"type-parameters-1",level:4},{value:"Returns",id:"returns",level:4},{value:"Properties",id:"properties",level:2},{value:"plugins",id:"plugins",level:3},{value:"Defined in",id:"defined-in",level:4},{value:"type",id:"type",level:3},{value:"Defined in",id:"defined-in-1",level:4},{value:"_instance",id:"_instance",level:3},{value:"Defined in",id:"defined-in-2",level:4},{value:"Methods",id:"methods",level:2},{value:"execute",id:"execute",level:3},{value:"Parameters",id:"parameters",level:4},{value:"Returns",id:"returns-1",level:4},{value:"Defined in",id:"defined-in-3",level:4},{value:"getInstance",id:"getinstance",level:3},{value:"Returns",id:"returns-2",level:4},{value:"Defined in",id:"defined-in-4",level:4}];function a(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",hr:"hr",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",...(0,l.R)(),...e.components};return(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(n.p,{children:(0,t.jsx)(n.strong,{children:(0,t.jsx)(n.code,{children:"Deprecated"})})}),"\n",(0,t.jsx)(n.p,{children:"Will be removed in future"}),"\n",(0,t.jsx)(n.h2,{id:"type-parameters",children:"Type parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,t.jsxs)(n.table,{children:[(0,t.jsx)(n.thead,{children:(0,t.jsxs)(n.tr,{children:[(0,t.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,t.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,t.jsx)(n.tbody,{children:(0,t.jsxs)(n.tr,{children:[(0,t.jsx)(n.td,{style:{textAlign:"left"},children:(0,t.jsx)(n.code,{children:"Type"})}),(0,t.jsxs)(n.td,{style:{textAlign:"left"},children:["extends ",(0,t.jsx)(n.a,{href:"/docs/api/enums/EventType",children:(0,t.jsx)(n.code,{children:"EventType"})})]})]})})]}),"\n",(0,t.jsx)(n.h2,{id:"constructors",children:"Constructors"}),"\n",(0,t.jsx)(n.h3,{id:"constructor",children:"constructor"}),"\n",(0,t.jsxs)(n.p,{children:["\u2022 ",(0,t.jsx)(n.strong,{children:"new EventExecutable"}),"<",(0,t.jsx)(n.code,{children:"Type"}),">(): ",(0,t.jsx)(n.a,{href:"/docs/api/classes/EventExecutable",children:(0,t.jsx)(n.code,{children:"EventExecutable"})}),"<",(0,t.jsx)(n.code,{children:"Type"}),">"]}),"\n",(0,t.jsx)(n.h4,{id:"type-parameters-1",children:"Type parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,t.jsxs)(n.table,{children:[(0,t.jsx)(n.thead,{children:(0,t.jsxs)(n.tr,{children:[(0,t.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,t.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,t.jsx)(n.tbody,{children:(0,t.jsxs)(n.tr,{children:[(0,t.jsx)(n.td,{style:{textAlign:"left"},children:(0,t.jsx)(n.code,{children:"Type"})}),(0,t.jsxs)(n.td,{style:{textAlign:"left"},children:["extends ",(0,t.jsx)(n.a,{href:"/docs/api/enums/EventType",children:(0,t.jsx)(n.code,{children:"EventType"})})]})]})})]}),"\n",(0,t.jsx)(n.h4,{id:"returns",children:"Returns"}),"\n",(0,t.jsxs)(n.p,{children:[(0,t.jsx)(n.a,{href:"/docs/api/classes/EventExecutable",children:(0,t.jsx)(n.code,{children:"EventExecutable"})}),"<",(0,t.jsx)(n.code,{children:"Type"}),">"]}),"\n",(0,t.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,t.jsx)(n.h3,{id:"plugins",children:"plugins"}),"\n",(0,t.jsxs)(n.p,{children:["\u2022 ",(0,t.jsx)(n.strong,{children:"plugins"}),": ",(0,t.jsx)(n.a,{href:"/docs/api/modules#anyeventplugin",children:(0,t.jsx)(n.code,{children:"AnyEventPlugin"})}),"[] = ",(0,t.jsx)(n.code,{children:"[]"})]}),"\n",(0,t.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,t.jsx)(n.p,{children:(0,t.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/modules.ts#L101",children:"src/core/modules.ts:101"})}),"\n",(0,t.jsx)(n.hr,{}),"\n",(0,t.jsx)(n.h3,{id:"type",children:"type"}),"\n",(0,t.jsxs)(n.p,{children:["\u2022 ",(0,t.jsx)(n.code,{children:"Abstract"})," ",(0,t.jsx)(n.strong,{children:"type"}),": ",(0,t.jsx)(n.code,{children:"Type"})]}),"\n",(0,t.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,t.jsx)(n.p,{children:(0,t.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/modules.ts#L100",children:"src/core/modules.ts:100"})}),"\n",(0,t.jsx)(n.hr,{}),"\n",(0,t.jsx)(n.h3,{id:"_instance",children:"_instance"}),"\n",(0,t.jsxs)(n.p,{children:["\u25aa ",(0,t.jsx)(n.code,{children:"Static"})," ",(0,t.jsx)(n.code,{children:"Private"})," ",(0,t.jsx)(n.strong,{children:"_instance"}),": ",(0,t.jsx)(n.a,{href:"/docs/api/modules#eventmodule",children:(0,t.jsx)(n.code,{children:"EventModule"})})]}),"\n",(0,t.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,t.jsx)(n.p,{children:(0,t.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/modules.ts#L103",children:"src/core/modules.ts:103"})}),"\n",(0,t.jsx)(n.h2,{id:"methods",children:"Methods"}),"\n",(0,t.jsx)(n.h3,{id:"execute",children:"execute"}),"\n",(0,t.jsxs)(n.p,{children:["\u25b8 ",(0,t.jsx)(n.strong,{children:"execute"}),"(",(0,t.jsx)(n.code,{children:"...args"}),"): ",(0,t.jsx)(n.code,{children:"unknown"})]}),"\n",(0,t.jsx)(n.h4,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,t.jsxs)(n.table,{children:[(0,t.jsx)(n.thead,{children:(0,t.jsxs)(n.tr,{children:[(0,t.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,t.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,t.jsx)(n.tbody,{children:(0,t.jsxs)(n.tr,{children:[(0,t.jsx)(n.td,{style:{textAlign:"left"},children:(0,t.jsx)(n.code,{children:"...args"})}),(0,t.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,t.jsx)(n.code,{children:"EventArgs"}),"<",(0,t.jsx)(n.code,{children:"Type"}),", ",(0,t.jsx)(n.a,{href:"/docs/api/enums/PluginType#control",children:(0,t.jsx)(n.code,{children:"Control"})}),">"]})]})})]}),"\n",(0,t.jsx)(n.h4,{id:"returns-1",children:"Returns"}),"\n",(0,t.jsx)(n.p,{children:(0,t.jsx)(n.code,{children:"unknown"})}),"\n",(0,t.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,t.jsx)(n.p,{children:(0,t.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/modules.ts#L112",children:"src/core/modules.ts:112"})}),"\n",(0,t.jsx)(n.hr,{}),"\n",(0,t.jsx)(n.h3,{id:"getinstance",children:"getInstance"}),"\n",(0,t.jsxs)(n.p,{children:["\u25b8 ",(0,t.jsx)(n.strong,{children:"getInstance"}),"(): ",(0,t.jsx)(n.a,{href:"/docs/api/modules#eventmodule",children:(0,t.jsx)(n.code,{children:"EventModule"})})]}),"\n",(0,t.jsx)(n.h4,{id:"returns-2",children:"Returns"}),"\n",(0,t.jsx)(n.p,{children:(0,t.jsx)(n.a,{href:"/docs/api/modules#eventmodule",children:(0,t.jsx)(n.code,{children:"EventModule"})})}),"\n",(0,t.jsx)(n.h4,{id:"defined-in-4",children:"Defined in"}),"\n",(0,t.jsx)(n.p,{children:(0,t.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/9d5c6c7/src/core/modules.ts#L104",children:"src/core/modules.ts:104"})})]})}function o(e={}){const{wrapper:n}={...(0,l.R)(),...e.components};return n?(0,t.jsx)(n,{...e,children:(0,t.jsx)(a,{...e})}):a(e)}},8453:(e,n,s)=>{s.d(n,{R:()=>d,x:()=>i});var t=s(6540);const l={},r=t.createContext(l);function d(e){const n=t.useContext(r);return t.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function i(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(l):e.components||l:d(e.components),t.createElement(r.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/c0930fba.2b67a718.js b/assets/js/c0930fba.2b67a718.js deleted file mode 100644 index 7ccbaec42..000000000 --- a/assets/js/c0930fba.2b67a718.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[1703],{8450:(e,t,n)=>{n.r(t),n.d(t,{assets:()=>c,contentTitle:()=>i,default:()=>u,frontMatter:()=>s,metadata:()=>a,toc:()=>d});var r=n(4848),o=n(8453);const s={sidebar_position:1},i="Create a new project",a={id:"guide/walkthrough/new-project",title:"Create a new project",description:"and follow the interactive prompts.",source:"@site/docs/guide/walkthrough/new-project.md",sourceDirName:"guide/walkthrough",slug:"/guide/walkthrough/new-project",permalink:"/docs/guide/walkthrough/new-project",draft:!1,unlisted:!1,editUrl:"https://github.com/sern-handler/website/edit/main/docs/guide/walkthrough/new-project.md",tags:[],version:"current",sidebarPosition:1,frontMatter:{sidebar_position:1},sidebar:"tutorialSidebar",previous:{title:"Goal",permalink:"/docs/guide/walkthrough/goal"},next:{title:"CLI",permalink:"/docs/guide/walkthrough/cli"}},c={},d=[];function l(e){const t={a:"a",code:"code",h1:"h1",p:"p",pre:"pre",...(0,o.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(t.h1,{id:"create-a-new-project",children:"Create a new project"}),"\n",(0,r.jsx)(t.pre,{children:(0,r.jsx)(t.code,{className:"language-sh",children:"npm create @sern/bot\n"})}),"\n",(0,r.jsx)(t.p,{children:"and follow the interactive prompts."}),"\n",(0,r.jsxs)(t.p,{children:["if somehow you need help, feel free to ask ",(0,r.jsx)(t.a,{href:"https://sern.dev/discord",children:"here"})]})]})}function u(e={}){const{wrapper:t}={...(0,o.R)(),...e.components};return t?(0,r.jsx)(t,{...e,children:(0,r.jsx)(l,{...e})}):l(e)}},8453:(e,t,n)=>{n.d(t,{R:()=>i,x:()=>a});var r=n(6540);const o={},s=r.createContext(o);function i(e){const t=r.useContext(s);return r.useMemo((function(){return"function"==typeof e?e(t):{...t,...e}}),[t,e])}function a(e){let t;return t=e.disableParentContext?"function"==typeof e.components?e.components(o):e.components||o:i(e.components),r.createElement(s.Provider,{value:t},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/c4348237.e83a81df.js b/assets/js/c4348237.e83a81df.js deleted file mode 100644 index 7a188700e..000000000 --- a/assets/js/c4348237.e83a81df.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[987],{4061:e=>{e.exports=JSON.parse('{"name":"docusaurus-plugin-content-pages","id":"default"}')}}]); \ No newline at end of file diff --git a/assets/js/c4f5d8e4.8e18ce01.js b/assets/js/c4f5d8e4.8e18ce01.js deleted file mode 100644 index d39db5db1..000000000 --- a/assets/js/c4f5d8e4.8e18ce01.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[2634],{6479:(e,t,l)=>{l.d(t,{A:()=>n});var c=l(6540);function a(){return a=Object.assign?Object.assign.bind():function(e){for(var t=1;t {let{title:t,titleId:l,...n}=e;return c.createElement("svg",a({height:800,width:800,xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512",xmlSpace:"preserve","aria-labelledby":l},n),t?c.createElement("title",{id:l},t):null,c.createElement("path",{style:{fill:"#e15649"},d:"M0 475.429h128v-73.143H0v73.143z"}),c.createElement("path",{style:{fill:"#bc342e"},d:"M128 475.429h128v-73.143H128v73.143z"}),c.createElement("path",{style:{fill:"#a52525"},d:"M256 475.429h128v-73.143H256v73.143z"}),c.createElement("path",{style:{fill:"#e15649"},d:"M384 475.429h128v-73.143H384v73.143z"}),c.createElement("path",{style:{fill:"#bc342e"},d:"M0 402.286h64v-73.143H0v73.143z"}),c.createElement("path",{style:{fill:"#a52525"},d:"M448 402.286h64v-73.143h-64v73.143zM64 402.286h128v-73.143H64v73.143z"}),c.createElement("path",{style:{fill:"#e15649"},d:"M192 402.286h128v-73.143H192v73.143z"}),c.createElement("path",{style:{fill:"#bc342e"},d:"M320 402.286h128v-73.143H320v73.143z"}),c.createElement("path",{style:{fill:"#e15649"},d:"M0 329.143h128V256H0v73.143z"}),c.createElement("path",{style:{fill:"#bc342e"},d:"M128 329.143h128V256H128v73.143z"}),c.createElement("path",{style:{fill:"#a52525"},d:"M256 329.143h128V256H256v73.143z"}),c.createElement("path",{style:{fill:"#e15649"},d:"M384 329.143h128V256H384v73.143z"}),c.createElement("path",{style:{fill:"#bc342e"},d:"M0 256h64v-73.143H0V256z"}),c.createElement("path",{style:{fill:"#a52525"},d:"M448 256h64v-73.143h-64V256zM64 256h128v-73.143H64V256z"}),c.createElement("path",{style:{fill:"#e15649"},d:"M192 256h128v-73.143H192V256z"}),c.createElement("path",{style:{fill:"#bc342e"},d:"M320 256h128v-73.143H320V256z"}),c.createElement("path",{style:{fill:"#e15649"},d:"M0 182.857h128v-73.143H0v73.143z"}),c.createElement("path",{style:{fill:"#bc342e"},d:"M128 182.857h128v-73.143H128v73.143z"}),c.createElement("path",{style:{fill:"#a52525"},d:"M256 182.857h128v-73.143H256v73.143z"}),c.createElement("path",{style:{fill:"#bc342e"},d:"M0 109.714h64V36.571H0v73.143z"}),c.createElement("path",{style:{fill:"#a52525"},d:"M64 109.714h128V36.571H64v73.143z"}))}},8804:(e,t,l)=>{l.d(t,{A:()=>d});var c,a,n,r,s,i=l(6540);function h(){return h=Object.assign?Object.assign.bind():function(e){for(var t=1;t {let{title:t,titleId:l,...d}=e;return i.createElement("svg",h({width:800,height:800,viewBox:"0 0 1024 1024",className:"icon",xmlns:"http://www.w3.org/2000/svg","aria-labelledby":l},d),t?i.createElement("title",{id:l},t):null,c||(c=i.createElement("path",{d:"M564.9 273.2V106.9c0-.9-.7-1.6-1.6-1.6-.1 0-.5 0-.9.3L478.9 189c-6.9 6.9-17.7 8-25.8 2.5-29.2-19.5-63.3-29.8-98.5-29.8s-69.3 10.3-98.5 29.8c-8.1 5.4-18.9 4.4-25.8-2.5l-83.4-83.4c-.4-.3-.8-.3-.9-.3-.9 0-1.6.7-1.6 1.6v166.3c0 12.9 1.2 25.8 3.5 38.6l62.4 8.3c11.2 1.5 19.1 11.8 17.6 23-1.3 10.3-10.1 17.7-20.2 17.7-.9 0-1.8 0-2.7-.2l-45-6c2.9 7.6 6.2 15 9.9 22.3l36-3c11.3-1 21.2 7.4 22.1 18.6 1 11.2-7.4 21.1-18.6 22.1l-14.8 1.2c3.8 4.9 7.9 9.8 12.1 14.4 40.5 44.3 93.1 68.7 148 68.7s107.5-24.4 148-68.7c4.2-4.6 8.3-9.4 12.1-14.4l-14.8-1.2c-11.2-1-19.6-10.9-18.6-22.1 1-11.3 10.8-19.6 22.1-18.6l36.1 3c3.7-7.3 7-14.7 9.9-22.3l-45 6c-.9.1-1.8.2-2.7.2-10.1 0-18.9-7.5-20.2-17.7-1.5-11.2 6.4-21.5 17.6-23l62.4-8.3c2.1-12.8 3.3-25.7 3.3-38.6zm283.6 570.3c65.7-109.7 30-250.7-81.3-320.9L573.4 400.1c-11 20.7-24.6 40.2-40.6 57.7-48.4 52.9-111.6 82-178.2 82-26.5 0-52.6-4.6-77.3-13.6-.2 6.7-.3 13.5-.1 20.3 1.5 55.7 16.9 110.5 44.7 158.4 2.7 4.7 3.3 9.9 2.2 14.8V856c0 11.3-9.2 20.4-20.4 20.4h-21.2c-11.7 0-21.3 9.5-21.3 21.2v21.3h104.2c11.3 0 20.4-9.2 20.4-20.4v-151c0-11.3 9.1-20.4 20.4-20.4 11.3 0 20.4 9.1 20.4 20.4v130.7h20.2c7.5-27.4 32.6-47.7 62.4-47.7h29.4c-6.5-19.5-9.9-40-9.9-60.6 0-104.8 85.2-190 190-190 11.3 0 20.4 9.1 20.4 20.4 0 11.3-9.2 20.4-20.4 20.4-82.2 0-149.1 66.9-149.1 149.2 0 24.9 6.3 49.5 18.1 71.3 3.5 6.3 3.3 14-.4 20.2-3.7 6.2-10.4 10-17.6 10h-60.5c-13.1 0-23.8 10.7-23.8 23.8V919h233.3c47.2 0 92.1-22.7 120.1-60.8l9.7-14.7zm33-262.4V319.5c0-9.8-3.8-19-10.7-25.9-6.9-6.9-16.2-10.8-26-10.8-20.2 0-36.7 16.5-36.7 36.7v181.6c30.2 22.5 54.8 49.8 73.4 80zm40.9-261.6v397.8c0 .4 0 .8-.1 1.2 1.2 49.8-11.3 100.3-38.8 146.2-.1.2-.3.5-.4.7-.1.1-.1.2-.2.2-3.3 5.7-6.9 11.2-10.8 16.4-35.6 48.8-93 77.9-153.4 77.9H485c-22.3 0-40.4-18.2-40.4-40.4v-.5h-21.4c-8.4 23.8-31.2 40.9-57.8 40.9H259.6c-21.6 0-39.2-17.6-39.2-39.3v-22.9c0-34.3 27.9-62.1 62.1-62.1h.8v-116c-29.1-52.4-45.3-111.7-46.9-171.9-.4-13.5 0-26.9 1.1-40.1-22.1-12.9-42.6-29.6-61-49.7-46.3-50.7-72.9-118-72.9-184.7V106.9c0-23.4 19-42.5 42.5-42.5 10.8 0 21.1 4 28.9 11.4l.5.5 72.4 72.4c32.5-18.3 69.1-27.8 106.8-27.8s74.2 9.6 106.8 27.8l72.4-72.4.5-.5c7.9-7.3 18.2-11.4 28.9-11.4 23.4 0 42.5 19.1 42.5 42.5v166.3c0 30.1-5.4 60.4-15.7 89.1l177.1 111.9V319.5c0-42.8 34.8-77.6 77.6-77.6 20.7 0 40.2 8.1 54.8 22.7 14.7 14.7 22.8 34.2 22.8 54.9z",fill:"#633"})),a||(a=i.createElement("path",{d:"M881.5 319.5v261.6c-18.5-30.2-43.2-57.5-73.4-80V319.5c0-20.2 16.5-36.7 36.7-36.7 9.8 0 19 3.8 26 10.8 6.9 6.9 10.7 16.1 10.7 25.9zM767.2 522.6c111.3 70.3 147 211.2 81.3 320.9l-9.7 14.8c-28 38-72.9 60.8-120.1 60.8H485.4v-23.8c0-13.1 10.7-23.8 23.8-23.8h60.5c7.2 0 13.9-3.8 17.6-10 3.7-6.2 3.8-13.9.4-20.2-11.8-21.7-18.1-46.4-18.1-71.3 0-82.3 66.9-149.2 149.1-149.2 11.3 0 20.4-9.2 20.4-20.4 0-11.3-9.2-20.4-20.4-20.4-104.8 0-190 85.2-190 190 0 20.6 3.4 41.1 9.9 60.6h-29.4c-29.8 0-54.9 20.2-62.4 47.7h-20.2V747.5c0-11.3-9.2-20.4-20.4-20.4-11.3 0-20.4 9.1-20.4 20.4v151.1c0 11.3-9.2 20.4-20.4 20.4H261.2v-21.3c0-11.7 9.5-21.2 21.3-21.2h21.2c11.3 0 20.4-9.2 20.4-20.4V719.8c1.1-4.9.5-10.1-2.2-14.8-27.8-47.9-43.2-102.7-44.7-158.4-.2-6.8-.1-13.6.1-20.3 24.8 8.9 50.8 13.6 77.3 13.6 66.6 0 129.8-29.1 178.2-82 16-17.5 29.6-37 40.6-57.7l193.8 122.4z",fill:"#B2ABAC"})),n||(n=i.createElement("path",{d:"M821.1 682.6c11 44.8 4.2 91.4-19.2 131.2-3.8 6.5-10.6 10.1-17.6 10.1-3.5 0-7.1-.9-10.3-2.8-9.8-5.7-13-18.2-7.3-28 18-30.6 23.2-66.4 14.7-100.8-2.7-11 4-22 15-24.7 10.9-2.6 22 4.1 24.7 15z",fill:"#633"})),r||(r=i.createElement("path",{d:"M564.9 106.9v166.3c0 12.9-1.2 25.8-3.5 38.6L499 320c-11.2 1.5-19.1 11.8-17.6 23 1.4 10.3 10.1 17.7 20.2 17.7.9 0 1.8-.1 2.7-.2l45-6c-2.9 7.6-6.2 15-9.9 22.3l-36.1-3c-11.3-1-21.1 7.4-22.1 18.6-.9 11.2 7.4 21.1 18.6 22.1l14.8 1.2c-3.8 4.9-7.9 9.8-12.1 14.4-40.5 44.3-93.1 68.7-148 68.7s-107.5-24.4-148-68.7c-4.2-4.6-8.3-9.4-12.1-14.4l14.8-1.2c11.2-1 19.6-10.9 18.6-22.1-.9-11.3-10.8-19.6-22.1-18.6l-36 3c-3.7-7.3-7-14.7-9.9-22.3l45 6c.9.1 1.8.2 2.7.2 10.1 0 18.9-7.5 20.2-17.7 1.5-11.2-6.4-21.5-17.6-23l-62.4-8.3c-2.3-12.8-3.5-25.7-3.5-38.6V106.9c0-.9.7-1.6 1.6-1.6.1 0 .5 0 .9.3l83.4 83.4c6.9 6.9 17.7 8 25.8 2.5 29.2-19.5 63.3-29.8 98.5-29.8s69.3 10.3 98.5 29.8c8.1 5.4 18.9 4.4 25.8-2.5l83.4-83.4c.4-.3.8-.3.9-.3 1.1 0 1.9.7 1.9 1.6z",fill:"#B2ABAC"})),s||(s=i.createElement("path",{d:"M461.4 277.9a20 20 0 1 0 40 0 20 20 0 1 0-40 0ZM414.5 356.4c5 8.8 1.9 20.1-6.9 25.1-7.4 4.2-15.7 6.4-24 6.4-3.4 0-6.7-.3-10-1-6.9-1.5-13.3-4.4-18.9-8.5-5.5 4.1-11.9 7-18.8 8.5-3.3.7-6.7 1-10 1-8.4 0-16.7-2.2-24.1-6.4-8.8-5-11.9-16.3-6.9-25.1 5-8.9 16.3-11.9 25.1-6.9 1.8 1 4.7 2.1 8.4 1.3 4.2-.9 7.6-3.9 8.9-8 3.1-9.6 13.5-14.9 23.2-11.8 5.8 1.9 10 6.4 11.8 11.8 1.3 4 4.7 7.1 8.9 8 3.7.8 6.6-.3 8.4-1.3 8.6-5 19.9-1.9 24.9 6.9zM207.8 277.9a20 20 0 1 0 40 0 20 20 0 1 0-40 0Z",fill:"#633"})))}},3382:(e,t,l)=>{l.d(t,{A:()=>i});var c,a,n,r=l(6540);function s(){return s=Object.assign?Object.assign.bind():function(e){for(var t=1;t {let{title:t,titleId:l,...i}=e;return r.createElement("svg",s({xmlns:"http://www.w3.org/2000/svg",width:800,height:800,viewBox:"0 0 64 64",xmlSpace:"preserve","aria-labelledby":l},i),t?r.createElement("title",{id:l},t):null,c||(c=r.createElement("path",{fill:"#394240",d:"M62.828 16.484 47.512 1.172a4 4 0 0 0-5.656 0L0 43.031V64h20.973l41.855-41.855a4.003 4.003 0 0 0 0-5.661zM18 56H8V46l.172-.172 10 10L18 56zm5.828-5.828-10-10L44 10l10 10-30.172 30.172z"})),a||(a=r.createElement("path",{fill:"#F9EBB2",d:"M18 56H8V46l.172-.172 10 10z"})),n||(n=r.createElement("path",{fill:"#45AAB8",d:"m44 10 10 10-30.171 30.17-10-10z"})))}},8831:(e,t,l)=>{l.r(t),l.d(t,{default:()=>f});l(6540);var c=l(53),a=l(5489),n=l(4586),r=l(8511);const s={features:"features_t9lD",featureSvg:"featureSvg_GfXr"};var i=l(4848);const h=[{title:"Modular",Svg:l(6479).A,description:(0,i.jsx)(i.Fragment,{children:"Take apart, build, or customize code with ease to create robust bots."})},{title:"Concise",Svg:l(3382).A,description:(0,i.jsx)(i.Fragment,{children:"Commands are significantly smaller than other competitors. Write impactful, concise code."})},{title:"Familiar",Svg:l(8804).A,description:(0,i.jsx)(i.Fragment,{children:"Code like a traditional command handler. Although not exactly the same, the api is easy to learn and resembles classic v12 command handlers."})}];function d(e){let{Svg:t,title:l,description:a}=e;return(0,i.jsxs)("div",{className:(0,c.A)("col col--4"),children:[(0,i.jsx)("div",{className:"text--center",children:(0,i.jsx)(t,{className:s.featureSvg,role:"img"})}),(0,i.jsxs)("div",{className:"text--center padding-horiz--md",children:[(0,i.jsx)("h3",{children:l}),(0,i.jsx)("p",{children:a})]})]})}function o(){return(0,i.jsx)("section",{className:s.features,children:(0,i.jsx)("div",{className:"container",children:(0,i.jsx)("div",{className:"row",children:h.map(((e,t)=>(0,i.jsx)(d,{...e},t)))})})})}const v=l.p+"assets/images/sern-logo-9d28d12a0f06ff725ef05a05847343db.png";var m=l(5648);function p(){const{siteConfig:e}=(0,n.A)();return(0,i.jsx)("header",{className:(0,c.A)("hero hero--primary-lighter",m.A.heroBanner),children:(0,i.jsx)("div",{className:"container",children:(0,i.jsxs)("div",{className:"container",children:[(0,i.jsxs)("div",{className:"row",children:[(0,i.jsxs)("div",{className:"col col--6",children:[(0,i.jsx)("h1",{allowFontScaling:!0,numberOfLines:1,adjustsFontSizeToFit:!0,className:(0,c.A)("hero__title",m.A["padding-vert--md"]),style:m.A.herotitle_font,children:(0,i.jsx)("b",{children:e.title.slice(6)})}),(0,i.jsx)("p",{className:"hero__subtitle",children:e.tagline}),(0,i.jsx)(a.A,{className:"button button--secondary button--lg",to:"docs/guide/walkthrough/new-project",children:"npm create @sern/bot"})]}),(0,i.jsx)("div",{className:"col col--6",children:(0,i.jsx)("img",{src:v,alt:"logo",height:"auto",width:"auto"})})]}),(0,i.jsx)("div",{className:m.A.buttons})]})})})}function f(){const{siteConfig:e}=(0,n.A)();return(0,i.jsxs)(r.A,{title:"sern - Handlers. Redefined.",description:"Description will go into a meta tag in",children:[(0,i.jsx)(p,{}),(0,i.jsx)("main",{className:"user-select-none",children:(0,i.jsx)(o,{})})]})}},5648:(e,t,l)=>{l.d(t,{A:()=>c});const c={heroBanner:"heroBanner_qdFl",header:"header_gB2a",buttons:"buttons_AeoN","padding-vert--md":"padding-vert--md_IMB4",cntnr:"cntnr_SOJH"}}}]); \ No newline at end of file diff --git a/assets/js/c606405e.60902698.js b/assets/js/c606405e.60902698.js deleted file mode 100644 index cd66b5e9b..000000000 --- a/assets/js/c606405e.60902698.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[4448],{2368:(e,n,i)=>{i.r(n),i.d(n,{assets:()=>c,contentTitle:()=>s,default:()=>o,frontMatter:()=>d,metadata:()=>t,toc:()=>h});var r=i(4848),l=i(8453);const d={id:"ExternalEventPlugin",title:"Interface: ExternalEventPlugin",sidebar_label:"ExternalEventPlugin",sidebar_position:0,custom_edit_url:null},s=void 0,t={id:"api/interfaces/ExternalEventPlugin",title:"Interface: ExternalEventPlugin",description:"Hierarchy",source:"@site/docs/api/interfaces/ExternalEventPlugin.md",sourceDirName:"api/interfaces",slug:"/api/interfaces/ExternalEventPlugin",permalink:"/docs/api/interfaces/ExternalEventPlugin",draft:!1,unlisted:!1,editUrl:null,tags:[],version:"current",sidebarPosition:0,frontMatter:{id:"ExternalEventPlugin",title:"Interface: ExternalEventPlugin",sidebar_label:"ExternalEventPlugin",sidebar_position:0,custom_edit_url:null},sidebar:"tutorialSidebar",previous:{title:"ExternalEventCommand",permalink:"/docs/api/interfaces/ExternalEventCommand"},next:{title:"Init",permalink:"/docs/api/interfaces/Init"}},c={},h=[{value:"Hierarchy",id:"hierarchy",level:2},{value:"Properties",id:"properties",level:2},{value:"description",id:"description",level:3},{value:"Inherited from",id:"inherited-from",level:4},{value:"Defined in",id:"defined-in",level:4},{value:"execute",id:"execute",level:3},{value:"Type declaration",id:"type-declaration",level:4},{value:"Parameters",id:"parameters",level:5},{value:"Returns",id:"returns",level:5},{value:"Defined in",id:"defined-in-1",level:4},{value:"name",id:"name",level:3},{value:"Inherited from",id:"inherited-from-1",level:4},{value:"Defined in",id:"defined-in-2",level:4},{value:"type",id:"type",level:3},{value:"Overrides",id:"overrides",level:4},{value:"Defined in",id:"defined-in-3",level:4}];function a(e){const n={a:"a",code:"code",h2:"h2",h3:"h3",h4:"h4",h5:"h5",hr:"hr",li:"li",p:"p",strong:"strong",table:"table",tbody:"tbody",td:"td",th:"th",thead:"thead",tr:"tr",ul:"ul",...(0,l.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(n.h2,{id:"hierarchy",children:"Hierarchy"}),"\n",(0,r.jsxs)(n.ul,{children:["\n",(0,r.jsxs)(n.li,{children:["\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:(0,r.jsx)(n.code,{children:"Plugin"})})}),"\n",(0,r.jsxs)(n.p,{children:["\u21b3 ",(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"ExternalEventPlugin"})})]}),"\n"]}),"\n"]}),"\n",(0,r.jsx)(n.h2,{id:"properties",children:"Properties"}),"\n",(0,r.jsx)(n.h3,{id:"description",children:"description"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"description"}),": ",(0,r.jsx)(n.code,{children:"string"})]}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Deprecated"})})}),"\n",(0,r.jsx)(n.p,{children:"will be removed in the next update"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from",children:"Inherited from"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:"Plugin"}),".",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin#description",children:"description"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L33",children:"src/handler/plugins/plugin.ts:33"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"execute",children:"execute"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"execute"}),": (",(0,r.jsx)(n.code,{children:"args"}),": ",(0,r.jsx)(n.code,{children:"unknown"}),"[], ",(0,r.jsx)(n.code,{children:"controller"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Controller",children:(0,r.jsx)(n.code,{children:"Controller"})}),") => ",(0,r.jsx)(n.code,{children:"Awaitable"}),"<",(0,r.jsx)(n.code,{children:"Result"}),"<",(0,r.jsx)(n.code,{children:"void"}),", ",(0,r.jsx)(n.code,{children:"void"}),">>"]}),"\n",(0,r.jsx)(n.h4,{id:"type-declaration",children:"Type declaration"}),"\n",(0,r.jsxs)(n.p,{children:["\u25b8 (",(0,r.jsx)(n.code,{children:"args"}),", ",(0,r.jsx)(n.code,{children:"controller"}),"): ",(0,r.jsx)(n.code,{children:"Awaitable"}),"<",(0,r.jsx)(n.code,{children:"Result"}),"<",(0,r.jsx)(n.code,{children:"void"}),", ",(0,r.jsx)(n.code,{children:"void"}),">>"]}),"\n",(0,r.jsx)(n.h5,{id:"parameters",children:"Parameters"}),"\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n",(0,r.jsxs)(n.table,{children:[(0,r.jsx)(n.thead,{children:(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Name"}),(0,r.jsx)(n.th,{style:{textAlign:"left"},children:"Type"})]})}),(0,r.jsxs)(n.tbody,{children:[(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"args"})}),(0,r.jsxs)(n.td,{style:{textAlign:"left"},children:[(0,r.jsx)(n.code,{children:"unknown"}),"[]"]})]}),(0,r.jsxs)(n.tr,{children:[(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.code,{children:"controller"})}),(0,r.jsx)(n.td,{style:{textAlign:"left"},children:(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Controller",children:(0,r.jsx)(n.code,{children:"Controller"})})})]})]})]}),"\n",(0,r.jsx)(n.h5,{id:"returns",children:"Returns"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.code,{children:"Awaitable"}),"<",(0,r.jsx)(n.code,{children:"Result"}),"<",(0,r.jsx)(n.code,{children:"void"}),", ",(0,r.jsx)(n.code,{children:"void"}),">>"]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-1",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L99",children:"src/handler/plugins/plugin.ts:99"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"name",children:"name"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.code,{children:"Optional"})," ",(0,r.jsx)(n.strong,{children:"name"}),": ",(0,r.jsx)(n.code,{children:"string"})]}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.strong,{children:(0,r.jsx)(n.code,{children:"Deprecated"})})}),"\n",(0,r.jsx)(n.p,{children:"will be removed in the next update"}),"\n",(0,r.jsx)(n.h4,{id:"inherited-from-1",children:"Inherited from"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:"Plugin"}),".",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin#name",children:"name"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-2",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L31",children:"src/handler/plugins/plugin.ts:31"})}),"\n",(0,r.jsx)(n.hr,{}),"\n",(0,r.jsx)(n.h3,{id:"type",children:"type"}),"\n",(0,r.jsxs)(n.p,{children:["\u2022 ",(0,r.jsx)(n.strong,{children:"type"}),": ",(0,r.jsx)(n.a,{href:"/docs/api/enums/PluginType#event",children:(0,r.jsx)(n.code,{children:"Event"})})]}),"\n",(0,r.jsx)(n.h4,{id:"overrides",children:"Overrides"}),"\n",(0,r.jsxs)(n.p,{children:[(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin",children:"Plugin"}),".",(0,r.jsx)(n.a,{href:"/docs/api/interfaces/Plugin#type",children:"type"})]}),"\n",(0,r.jsx)(n.h4,{id:"defined-in-3",children:"Defined in"}),"\n",(0,r.jsx)(n.p,{children:(0,r.jsx)(n.a,{href:"https://github.com/sern-handler/handler/blob/3daacfc/src/handler/plugins/plugin.ts#L98",children:"src/handler/plugins/plugin.ts:98"})})]})}function o(e={}){const{wrapper:n}={...(0,l.R)(),...e.components};return n?(0,r.jsx)(n,{...e,children:(0,r.jsx)(a,{...e})}):a(e)}},8453:(e,n,i)=>{i.d(n,{R:()=>s,x:()=>t});var r=i(6540);const l={},d=r.createContext(l);function s(e){const n=r.useContext(d);return r.useMemo((function(){return"function"==typeof e?e(n):{...n,...e}}),[n,e])}function t(e){let n;return n=e.disableParentContext?"function"==typeof e.components?e.components(l):e.components||l:s(e.components),r.createElement(d.Provider,{value:n},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/ccc49370.93ff3c1b.js b/assets/js/ccc49370.93ff3c1b.js deleted file mode 100644 index c942da6a0..000000000 --- a/assets/js/ccc49370.93ff3c1b.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[3249],{4029:(e,n,t)=>{t.r(n),t.d(n,{default:()=>p});t(6540);var i=t(53),s=t(9024),a=t(7559),r=t(7131),o=t(6535),l=t(8258),c=t(1312),d=t(9022),u=t(4848);function m(e){const{nextItem:n,prevItem:t}=e;return(0,u.jsxs)("nav",{className:"pagination-nav docusaurus-mt-lg","aria-label":(0,c.T)({id:"theme.blog.post.paginator.navAriaLabel",message:"Blog post page navigation",description:"The ARIA label for the blog posts pagination"}),children:[t&&(0,u.jsx)(d.A,{...t,subLabel:(0,u.jsx)(c.A,{id:"theme.blog.post.paginator.newerPost",description:"The blog post button label to navigate to the newer/previous post",children:"Newer Post"})}),n&&(0,u.jsx)(d.A,{...n,subLabel:(0,u.jsx)(c.A,{id:"theme.blog.post.paginator.olderPost",description:"The blog post button label to navigate to the older/next post",children:"Older Post"}),isNext:!0})]})}function g(){const{assets:e,metadata:n}=(0,r.e)(),{title:t,description:i,date:a,tags:o,authors:l,frontMatter:c}=n,{keywords:d}=c,m=e.image??c.image;return(0,u.jsxs)(s.be,{title:t,description:i,keywords:d,image:m,children:[(0,u.jsx)("meta",{property:"og:type",content:"article"}),(0,u.jsx)("meta",{property:"article:published_time",content:a}),l.some((e=>e.url))&&(0,u.jsx)("meta",{property:"article:author",content:l.map((e=>e.url)).filter(Boolean).join(",")}),o.length>0&&(0,u.jsx)("meta",{property:"article:tag",content:o.map((e=>e.label)).join(",")})]})}var h=t(7763),f=t(996);function v(e){let{sidebar:n,children:t}=e;const{metadata:i,toc:s}=(0,r.e)(),{nextItem:a,prevItem:c,frontMatter:d,unlisted:g}=i,{hide_table_of_contents:v,toc_min_heading_level:p,toc_max_heading_level:x}=d;return(0,u.jsxs)(o.A,{sidebar:n,toc:!v&&s.length>0?(0,u.jsx)(h.A,{toc:s,minHeadingLevel:p,maxHeadingLevel:x}):void 0,children:[g&&(0,u.jsx)(f.A,{}),(0,u.jsx)(l.A,{children:t}),(a||c)&&(0,u.jsx)(m,{nextItem:a,prevItem:c})]})}function p(e){const n=e.content;return(0,u.jsx)(r.i,{content:e.content,isBlogPostPage:!0,children:(0,u.jsxs)(s.e3,{className:(0,i.A)(a.G.wrapper.blogPages,a.G.page.blogPostPage),children:[(0,u.jsx)(g,{}),(0,u.jsx)(v,{sidebar:e.sidebar,children:(0,u.jsx)(n,{})})]})})}},7763:(e,n,t)=>{t.d(n,{A:()=>c});t(6540);var i=t(53),s=t(5195);const a={tableOfContents:"tableOfContents_bqdL",docItemContainer:"docItemContainer_F8PC"};var r=t(4848);const o="table-of-contents__link toc-highlight",l="table-of-contents__link--active";function c(e){let{className:n,...t}=e;return(0,r.jsx)("div",{className:(0,i.A)(a.tableOfContents,"thin-scrollbar",n),children:(0,r.jsx)(s.A,{...t,linkClassName:o,linkActiveClassName:l})})}},5195:(e,n,t)=>{t.d(n,{A:()=>f});var i=t(6540),s=t(6342);function a(e){const n=e.map((e=>({...e,parentIndex:-1,children:[]}))),t=Array(7).fill(-1);n.forEach(((e,n)=>{const i=t.slice(2,e.level);e.parentIndex=Math.max(...i),t[e.level]=n}));const i=[];return n.forEach((e=>{const{parentIndex:t,...s}=e;t>=0?n[t].children.push(s):i.push(s)})),i}function r(e){let{toc:n,minHeadingLevel:t,maxHeadingLevel:i}=e;return n.flatMap((e=>{const n=r({toc:e.children,minHeadingLevel:t,maxHeadingLevel:i});return function(e){return e.level>=t&&e.level<=i}(e)?[{...e,children:n}]:n}))}function o(e){const n=e.getBoundingClientRect();return n.top===n.bottom?o(e.parentNode):n}function l(e,n){let{anchorTopOffset:t}=n;const i=e.find((e=>o(e).top>=t));if(i){return function(e){return e.top>0&&e.bottom {e.current=n?0:document.querySelector(".navbar").clientHeight}),[n]),e}function d(e){const n=(0,i.useRef)(void 0),t=c();(0,i.useEffect)((()=>{if(!e)return()=>{};const{linkClassName:i,linkActiveClassName:s,minHeadingLevel:a,maxHeadingLevel:r}=e;function o(){const e=function(e){return Array.from(document.getElementsByClassName(e))}(i),o=function(e){let{minHeadingLevel:n,maxHeadingLevel:t}=e;const i=[];for(let s=n;s<=t;s+=1)i.push(`h${s}.anchor`);return Array.from(document.querySelectorAll(i.join()))}({minHeadingLevel:a,maxHeadingLevel:r}),c=l(o,{anchorTopOffset:t.current}),d=e.find((e=>c&&c.id===function(e){return decodeURIComponent(e.href.substring(e.href.indexOf("#")+1))}(e)));e.forEach((e=>{!function(e,t){t?(n.current&&n.current!==e&&n.current.classList.remove(s),e.classList.add(s),n.current=e):e.classList.remove(s)}(e,e===d)}))}return document.addEventListener("scroll",o),document.addEventListener("resize",o),o(),()=>{document.removeEventListener("scroll",o),document.removeEventListener("resize",o)}}),[e,t])}var u=t(5489),m=t(4848);function g(e){let{toc:n,className:t,linkClassName:i,isChild:s}=e;return n.length?(0,m.jsx)("ul",{className:s?void 0:t,children:n.map((e=>(0,m.jsxs)("li",{children:[(0,m.jsx)(u.A,{to:`#${e.id}`,className:i??void 0,dangerouslySetInnerHTML:{__html:e.value}}),(0,m.jsx)(g,{isChild:!0,toc:e.children,className:t,linkClassName:i})]},e.id)))}):null}const h=i.memo(g);function f(e){let{toc:n,className:t="table-of-contents table-of-contents__left-border",linkClassName:o="table-of-contents__link",linkActiveClassName:l,minHeadingLevel:c,maxHeadingLevel:u,...g}=e;const f=(0,s.p)(),v=c??f.tableOfContents.minHeadingLevel,p=u??f.tableOfContents.maxHeadingLevel,x=function(e){let{toc:n,minHeadingLevel:t,maxHeadingLevel:s}=e;return(0,i.useMemo)((()=>r({toc:a(n),minHeadingLevel:t,maxHeadingLevel:s})),[n,t,s])}({toc:n,minHeadingLevel:v,maxHeadingLevel:p});return d((0,i.useMemo)((()=>{if(o&&l)return{linkClassName:o,linkActiveClassName:l,minHeadingLevel:v,maxHeadingLevel:p}}),[o,l,v,p])),(0,m.jsx)(h,{toc:x,className:t,linkClassName:o,...g})}},996:(e,n,t)=>{t.d(n,{A:()=>g});t(6540);var i=t(53),s=t(1312),a=t(5260),r=t(4848);function o(){return(0,r.jsx)(s.A,{id:"theme.unlistedContent.title",description:"The unlisted content banner title",children:"Unlisted page"})}function l(){return(0,r.jsx)(s.A,{id:"theme.unlistedContent.message",description:"The unlisted content banner message",children:"This page is unlisted. Search engines will not index it, and only users having a direct link can access it."})}function c(){return(0,r.jsx)(a.A,{children:(0,r.jsx)("meta",{name:"robots",content:"noindex, nofollow"})})}var d=t(7559),u=t(7293);function m(e){let{className:n}=e;return(0,r.jsx)(u.A,{type:"caution",title:(0,r.jsx)(o,{}),className:(0,i.A)(n,d.G.common.unlistedBanner),children:(0,r.jsx)(l,{})})}function g(e){return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(c,{}),(0,r.jsx)(m,{...e})]})}},4428:(e,n,t)=>{t.d(n,{A:()=>l});var i=t(6540),s=t(2303),a=t(6846),r=t(3717),o=t(4848);function l(e){let{children:n,...t}=e;const l=(0,s.A)(),c=function(e){return i.Children.toArray(e).some((e=>(0,i.isValidElement)(e)))?e:Array.isArray(e)?e.join(""):e}(n),d="string"==typeof c?r.A:a.A;return(0,o.jsx)(d,{...t,children:c},String(l))}}}]); \ No newline at end of file diff --git a/assets/js/cf183316.3eea489e.js b/assets/js/cf183316.3eea489e.js deleted file mode 100644 index 5e8a90c4c..000000000 --- a/assets/js/cf183316.3eea489e.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[152],{6137:(e,t,n)=>{n.r(t),n.d(t,{assets:()=>d,contentTitle:()=>o,default:()=>h,frontMatter:()=>i,metadata:()=>c,toc:()=>l});var r=n(4848),s=n(8453);const i={sidebar_position:8},o="The SernEmitter class",c={id:"guide/walkthrough/sern-emitter",title:"The SernEmitter class",description:"You're shipped with the SernEmitter. This EventEmitter listens to",source:"@site/docs/guide/walkthrough/sern-emitter.md",sourceDirName:"guide/walkthrough",slug:"/guide/walkthrough/sern-emitter",permalink:"/docs/guide/walkthrough/sern-emitter",draft:!1,unlisted:!1,editUrl:"https://github.com/sern-handler/website/edit/main/docs/guide/walkthrough/sern-emitter.md",tags:[],version:"current",sidebarPosition:8,frontMatter:{sidebar_position:8},sidebar:"tutorialSidebar",previous:{title:"Dependency Injection",permalink:"/docs/guide/walkthrough/dependency-injection"},next:{title:"Conclusion",permalink:"/docs/guide/walkthrough/conclusion"}},d={},l=[];function a(e){const t={a:"a",br:"br",code:"code",h1:"h1",li:"li",p:"p",ul:"ul",...(0,s.R)(),...e.components};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(t.h1,{id:"the-sernemitter-class",children:"The SernEmitter class"}),"\n",(0,r.jsx)(t.p,{children:"You're shipped with the SernEmitter. This EventEmitter listens to"}),"\n",(0,r.jsxs)(t.ul,{children:["\n",(0,r.jsxs)(t.li,{children:["command modules executing and its status, the ",(0,r.jsx)(t.code,{children:"module.activate"})," event"]}),"\n",(0,r.jsxs)(t.li,{children:["command modules registered and its status, the ",(0,r.jsx)(t.code,{children:"module.register"})," event"]}),"\n",(0,r.jsx)(t.li,{children:"On default, sern creates a single SernEmitter for your bot process."}),"\n",(0,r.jsxs)(t.li,{children:["any error that occurs, the ",(0,r.jsx)(t.code,{children:"error"})," event"]}),"\n",(0,r.jsxs)(t.li,{children:[(0,r.jsx)(t.code,{children:"warn"})," events, where it is possible to throw errors"]}),"\n"]}),"\n",(0,r.jsxs)(t.p,{children:["You can put these and other event listeners into ",(0,r.jsx)(t.a,{href:"/docs/guide/walkthrough/first-event",children:"event modules"}),"!\n",(0,r.jsx)(t.br,{}),"View all ",(0,r.jsx)(t.a,{href:"https://sern.dev/docs/api/modules#serneventsmapping",children:"events"})]})]})}function h(e={}){const{wrapper:t}={...(0,s.R)(),...e.components};return t?(0,r.jsx)(t,{...e,children:(0,r.jsx)(a,{...e})}):a(e)}},8453:(e,t,n)=>{n.d(t,{R:()=>o,x:()=>c});var r=n(6540);const s={},i=r.createContext(s);function o(e){const t=r.useContext(i);return r.useMemo((function(){return"function"==typeof e?e(t):{...t,...e}}),[t,e])}function c(e){let t;return t=e.disableParentContext?"function"==typeof e.components?e.components(s):e.components||s:o(e.components),r.createElement(i.Provider,{value:t},e.children)}}}]); \ No newline at end of file diff --git a/assets/js/cfb1619e.f2ad3e8a.js b/assets/js/cfb1619e.f2ad3e8a.js deleted file mode 100644 index b43b5276e..000000000 --- a/assets/js/cfb1619e.f2ad3e8a.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[6570],{2800:e=>{e.exports=JSON.parse('{"permalink":"/blog/tags/guides","page":1,"postsPerPage":10,"totalPages":1,"totalCount":2,"blogDescription":"Blog","blogTitle":"Blog"}')}}]); \ No newline at end of file diff --git a/assets/js/d9ea5336.cd1b3e0a.js b/assets/js/d9ea5336.cd1b3e0a.js deleted file mode 100644 index 601fb4f34..000000000 --- a/assets/js/d9ea5336.cd1b3e0a.js +++ /dev/null @@ -1 +0,0 @@ -"use strict";(self.webpackChunksern_website=self.webpackChunksern_website||[]).push([[2427],{2503:(e,n,l)=>{l.r(n),l.d(n,{assets:()=>c,contentTitle:()=>t,default:()=>o,frontMatter:()=>d,metadata:()=>s,toc:()=>a});var i=l(4848),r=l(8453);const d={id:"Logging",title:"Interface: Logging