execute method

Stream<State> execute(
  1. StateReader<State> state,
  2. Dispatcher dispatch,
  3. ServiceLocator services

Execute asynchronous logic to send state updates to a Store<State>.

The state reads the current value of the store. It should be read regularly during all the execution to make sure to sends up-to-date versions of a new resulting state.

The dispatch allows to trigger new actions execution from the store.

The service allows you to instanciate services that may have external logic.


Stream<State> execute(
  StateReader<State> state,
  Dispatcher dispatch,
  ServiceLocator services,