Skip to content

Type Alias: EventHandler<E> ​

ts
type EventHandler<E> = (event: E) => void;

Defined in: src/wirestate-core/plugin/events/events.ts:73

Receives an emitted event from the bus.

Type Parameters ​

Type ParameterDefault typeDescription
E extends WireEventWireEventEvent shape delivered to the handler.

Parameters ​

ParameterType
eventE

Returns ​

void

Remarks ​

May start asynchronous work. The bus does not await a returned promise, and reports a rejection through the container error handler.