2 ms·
The alternative is side-effects. Pick your poison, redux-sagas, redux-thunk, etc. I prefer redux-sagas because generators fit the bill perfectly, and they test
by s_y_n_t_a_x 8y ago
The alternative is side-effects. Pick your poison, redux-sagas, redux-thunk, etc.
I prefer redux-sagas because generators fit the bill perfectly, and they test easy, and I'm not a huge fan of Observables.
The components dispatch an action, and the heavy-lifting is done by the side-effects library that listens for that action, and does any API calls, as well as dispatching any more actions.
- deleted 8y ago[deleted]