This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
This is an example of managing application state using the React Context API | |
and the useReducer hook in typescript. It demonstrates a pattern commonly | |
used in React applications to provide global state management and share state | |
and actions across components. It is all implemented in a single file for easy | |
copy/paste. | |
- Author: Chris Fogelklou | |
- Tags: useContext, Provider, useReducer, createContext |