Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/naufaldi/movie-react-context
Movie React Context TUtorial
https://github.com/naufaldi/movie-react-context
Last synced: 10 days ago
JSON representation
Movie React Context TUtorial
- Host: GitHub
- URL: https://github.com/naufaldi/movie-react-context
- Owner: naufaldi
- Created: 2020-11-13T16:53:51.000Z (about 4 years ago)
- Default Branch: master
- Last Pushed: 2020-11-13T16:54:52.000Z (about 4 years ago)
- Last Synced: 2024-11-14T17:51:39.411Z (2 months ago)
- Language: JavaScript
- Size: 207 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Tutorial From Dev Ed
URL : [React State Management Tutorial | Context Api | React Tutorial For Beginners](https://www.youtube.com/watch?v=35lXWvCuM8o)
## Notes From Tania
URL : [Using Context API in React (Hooks and Classes)](https://www.taniarascia.com/using-context-api-in-react/)
Imagine I have some information I want to be available anywhere or everywhere throughout a React app. A theme might be implemented using Context - for example, on this site I have Context serving three themes: dark mode, light mode, and MS-DOS mode (on the 404 page).In this simple example, I'll use a logged in user.I'll create Context, and call it UserContext. This will also give me UserContext.Provider and UserContext.Consumer. What these two components do is straightforward:
Provider - The component that provides the value
Consumer - A component that is consuming the value