Skip to main content

Namespace: Sern

References

CommandExecutable

Re-exports CommandExecutable


EventExecutable

Re-exports EventExecutable


commandModule

Re-exports commandModule


eventModule

Re-exports eventModule

Variables

controller

Const controller: Object

The object passed into every plugin to control a command's behavior

Type declaration

NameType
next() => OkImpl<void>
stop() => ErrImpl<void>

Defined in

src/handler/sern.ts:55

Functions

init

init(wrapper): void

Example

src/index.ts
Sern.init({
defaultPrefix: '!',
commands: 'dist/commands',
events: 'dist/events',
containerConfig : {
get: useContainer
}
})

Parameters

NameTypeDescription
wrapperWrapperOptions to pass into sern. Function to start the handler up

Returns

void

Defined in

src/handler/sern.ts:38


makeDependencies

makeDependencies<T>(conf): <V>(...keys: [...V[]]) => MapDeps<T, V>

Type parameters

NameType
Textends Dependencies

Parameters

NameTypeDescription
confObjecta configuration for creating your project dependencies
conf.build(root: Container<Record<string, unknown>, {}>) => Container<Partial<T>, {}>-
conf.exclude?Set``"@sern/logger"``\-

Returns

fn

▸ <V>(...keys): MapDeps<T, V>

Type parameters
NameType
Vextends keyof T[]
Parameters
NameType
...keys[...V[]]
Returns

MapDeps<T, V>

Defined in

src/handler/sern.ts:87