-
Notifications
You must be signed in to change notification settings - Fork 176
High level app architecture
Vladimir Grichina edited this page May 21, 2019
·
3 revisions
- https://redux.js.org/advanced/async-actions
- https://redux.js.org/advanced/middleware#seven-examples
- https://redux-actions.js.org/
- Dispatch action with promise (defined using redux-actions)
- Redux middleware handles promises (see
readyStatePromise
) - Redux reducers update state based on promise result actions
- Completed requests have
{ requestStatus: { success: true, message: 'myRequest.success' }
in state. - In-flight requests have
{ formLoader: true }
in state.
- Completed requests have
- React components are used to render UI. E.g.
RequestStatusBox
can be used to displayrequestStatus
from Redux state.