Type alias EventReducer<S, E, K>

EventReducer<S, E, K>: ((state, event) => Readonly<Patch<S>>)

Type Parameters

Type declaration

    • (state, event): Readonly<Patch<S>>
    • Event reducers apply events to a reduced state, and returns the new patch

      • state the current reduced state
      • event the event to be applied

      Parameters

      Returns Readonly<Patch<S>>

Generated using TypeDoc