whenStateAction method

void whenStateAction(
  1. Map<Object, Function> actions
)

Handle what happens when an action is called actions is a map of actions

E.g. whenStateAction({ 'logout': () async { await Auth.logout(); routeToInitial(); } });

Implementation

void whenStateAction(Map<Object, Function> actions) {
  _stateActions = actions;
}