useContext-Intermediate is a collection of three intermediate-level React projects that showcase practical use cases of the useContext
hook for global state management. These projects simulate real-world features like shopping carts, user preferences, and task filtering.
-
ShoppingCart-Context
Build a shopping cart with global state, item management, and persistence usingCartContext
. -
UserSettings-Context
Manage user preferences like theme and language across the app usingSettingsContext
andAuthContext
. -
TaskManager-Context
Create a task manager with filtering capabilities usingTasksContext
andFilterContext
.
Each project is located in its own folder. You can run them individually:
cd ProjectFolderName
npm install
npm run dev
cd ShoppingCart-Context
npm install
npm run dev
- Node.js and npm installed
- Solid understanding of React basics
- Familiarity with useContext
- Creating multiple context providers
- Composing contexts to manage complex state
- Real-world patterns like persistence, filtering, and user settings
Feel free to submit issues or pull requests to improve this project.
This project is licensed under the MIT License.
Made with ❤️ by Espadv69