Processes state and makes changes based on the action and / or state.
While the ActionHandler is a synchronous function it may have side effects
(start asynchronous actions) and can invoke "dispatch" to queue up new
actions.
Returns
A tuple, the first element is an object of type T. The optional
second element indicates if the state has changed; if not provided it
defaults to false.
Processes state and makes changes based on the
action
and / orstate
. While the ActionHandler is a synchronous function it may have side effects (start asynchronous actions) and can invoke "dispatch" to queue up new actions.Returns
A tuple, the first element is an object of type
T
. The optional second element indicates if the state has changed; if not provided it defaults to false.