[Step2-0(7,8)] Update to docs.

This commit is contained in:
JD Huntington
2019-02-25 11:52:43 -08:00
parent 19049fe361
commit 6c876b71eb
2 changed files with 11 additions and 7 deletions

View File

@@ -18,6 +18,8 @@ This `mapStateToProps` function selects out portions of the state tree. This fun
2. open up `exercise/src/components/TodoFooter.tsx` and erase the "nullable" type modifier (i.e. the ?) in the interface definition of `TodoFooterProps` 2. open up `exercise/src/components/TodoFooter.tsx` and erase the "nullable" type modifier (i.e. the ?) in the interface definition of `TodoFooterProps`
3. uncomment the bottom bits of code and fill in the implementation for `mapStateToProps()` and `mapDispatchToProps()` - feel free to use `TodoListItem.tsx` as a guide 3. Remove the `export` from `export const TodoFooter = (props: TodoFooterProps) => {`
4. do steps 2 and 3 for the `TodoHeader.tsx` file 4. uncomment the bottom bits of code and fill in the implementation for `mapStateToProps()` and `mapDispatchToProps()` - feel free to use `TodoListItem.tsx` as a guide
5. do steps 2, 3, and 4 for the `TodoHeader.tsx` file

View File

@@ -43,11 +43,7 @@ export const reducer = combineReducers({
}); });
``` ```
# Take a peek at useful helpers and middleware created by community are: `combineReducers` handles the grunt-work of sending *actions* to each combined reducer. Therefore, when an action arrives, each reducer is given the opportunity to modify its own state tree based on the incoming action.
- immer: https://github.com/mweststrate/immer - improves ergonomics of working with immutables by introducing the concept of mutating a draft
- redux-starter-kit: https://github.com/reduxjs/redux-starter-kit - help address common concerns of Redux in boilerplate and complexity
# Exercise # Exercise
@@ -68,3 +64,9 @@ The Redux team came up with `redux-starter-kit` to address a lot of boilerplate
3. run `npm test` in the root folder to see if it still works! 3. run `npm test` in the root folder to see if it still works!
4. look at the web app to make sure it still works! 4. look at the web app to make sure it still works!
# Further reading
- immer: https://github.com/mweststrate/immer - improves ergonomics of working with immutables by introducing the concept of mutating a draft
- redux-starter-kit: https://github.com/reduxjs/redux-starter-kit - help address common concerns of Redux in boilerplate and complexity