January 2019
Intermediate to advanced
592 pages
14h 30m
English
In step 3, we imported the action creators we created in the earlier recipe, Defining actions. Even though we don't yet have a UI, we can use the Redux store and observe the changes as they happen. All it takes is calling an action creator and then dispatching the resulting action.
In step 5, we called the dispatch method from the store instance. dispatch takes an action, which is created by the loadBookmarks action creator. The reducer will be called in turn, which will set the new photos on the state.
Once we have our UI in place, we'll dispatch the actions in a similar fashion from our components, which will update the state, ultimately triggering a re-render of the component, displaying the new data.
Read now
Unlock full access