- Install modules to work add redux to a react application
- Create a redux store and connect it to react
- Create a reducer
- Create an action
- Explain the flow of information and actions of react and redux
- Install the following node modules
reduxreact-redux
- Create
src/reducer.jsfileimport { combineReducers } from reduxexport default combineReducer({})
- In
src/index.jsimport { createStore } from 'redux'import { Provider } from 'react-redux'- Create store
- Add store to the React Application
- In
src/reducer.js- Create reducer
- Add new reducer to
combineReducer
- In
App.js- Replace class component with a functional component
- import { connect } from 'react-redux'
- Create
mapStateToProps - connect component
- create render
- Create
src/actions.jsfile- Create
action creator - import action creator to
App.js - trigger action creator
- Create
- With your tables, explain how data flow from a reducer to a component
- With your groups, explain how the state can be updated
- Replicate the To Do application using Redux
- Update To Do application to use Redux