Type Alias WithEventBusSchemaSettings

WithEventBusSchemaSettings: {
    eventMapSchema: EventMapSchema;
    shouldValidateListeners?: boolean;
}

Settings for the withEventBusSchema plugin.

IMPORT_PATH: "@daiso-tech/core/event-bus/plugins"

Type declaration

  • eventMapSchema: EventMapSchema

    A map of event names to standard-schema-compliant schemas. Compatible with libraries such as Zod, ArkType, Valibot, and others that implement the StandardSchemaV1 specification.

  • OptionalshouldValidateListeners?: boolean

    Whether to validate event data in listener functions when events are received, in addition to validating on dispatch. When true, listeners will receive validated event data that conforms to the schema.

    true