Sporades SDK API
    Preparing search index...

    Type Alias CapsuleHooks<Schema>

    Capsule lifecycle hooks around named mutations.

    type CapsuleHooks<Schema extends SchemaDefinition = SchemaDefinition> = {
        afterMutation?: MutationHook<Schema>[];
        beforeMutation?: MutationHook<Schema>[];
        init?: (ctx: CapsuleContext<Schema>) => MaybePromise<void>;
        shutdown?: (ctx: CapsuleContext<Schema>) => MaybePromise<void>;
    }

    Type Parameters

    Index
    afterMutation?: MutationHook<Schema>[]
    beforeMutation?: MutationHook<Schema>[]
    init?: (ctx: CapsuleContext<Schema>) => MaybePromise<void>
    shutdown?: (ctx: CapsuleContext<Schema>) => MaybePromise<void>