August 2017
Beginner
298 pages
7h 4m
English
We wrapped the entire App component of our blog inside the BrowserRouter component of React router to implement routing in the index.js file. Redux follows a similar approach. We need to wrap the App component, which is already wrapped inside the router within a Provider component of the react-redux library.
Open your src/index.js file, and add the following import statements after the import statements that are already present in the file:
import { Provider } from 'react-redux';import configureStore from './redux/store/configureStore';
This will import the Provider component of react-redux and the configureStore function that we created in the preceding section. We will need to create a store object ...
Read now
Unlock full access