-
Added
/src/actions/
folder that contains all of the Counter Actions -
Changed all string literals to const exports for the following reasons (all imported from the Redux Docs):
- It helps keep the naming consistent because all action types are gathered in a single place.
- Sometimes you want to see all existing actions before working on a new feature. It may be that the action you need was already added by somebody on the team, but you didn't know.
- The list of action types that were added, removed, and changed in a Pull Request helps everyone on the team keep track of scope and implementation of new features.
- If you make a typo when importing an action constant, you will get
undefined
. Redux will immediately throw when dispatching such an action, and you'll find the mistake sooner.