chore(readme): Update readme
This commit is contained in:
parent
a0ab58e948
commit
9fe5f3f0b7
14
readme.md
14
readme.md
|
@ -5,6 +5,13 @@
|
||||||
|
|
||||||
Are you fed up of hand coding the same pattern over and over again? Fed up of conflicting action names causing your button presses to set off your ajax loading animation? Are you a fan of having a strictly defined structure for your redux store, down to the type level? Then redux-scc may be for you!
|
Are you fed up of hand coding the same pattern over and over again? Fed up of conflicting action names causing your button presses to set off your ajax loading animation? Are you a fan of having a strictly defined structure for your redux store, down to the type level? Then redux-scc may be for you!
|
||||||
|
|
||||||
|
### Installing
|
||||||
|
Install via yarn or npm:
|
||||||
|
|
||||||
|
```
|
||||||
|
yarn add redux-scc
|
||||||
|
```
|
||||||
|
|
||||||
#### What does it do?
|
#### What does it do?
|
||||||
It takes a defined structure and uses a set of 'behaviors' (a small collection of ways that a reducer can
|
It takes a defined structure and uses a set of 'behaviors' (a small collection of ways that a reducer can
|
||||||
be updated) to create a set of actions and reducer responses. A selector is also created for every reducer defined, and the set of action generators, selectors, and reducers are then returned.
|
be updated) to create a set of actions and reducer responses. A selector is also created for every reducer defined, and the set of action generators, selectors, and reducers are then returned.
|
||||||
|
@ -140,6 +147,13 @@ const exampleBatchedUpdateHittingSameReducerMultipleTimes = createCombinedAction
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
|
#### resetAll
|
||||||
|
The special `resetAll` action is available for nested reducers (i.e. those where more than just one reducer has been defined in the chunk). Calling this action allows you to reset all of the reducers in the chunk simultaneously.
|
||||||
|
|
||||||
|
```
|
||||||
|
store.dispatch(actions.resetAll());
|
||||||
|
```
|
||||||
|
|
||||||
#### Examples
|
#### Examples
|
||||||
|
|
||||||
##### Basic
|
##### Basic
|
||||||
|
|
Loading…
Reference in New Issue