Skip to content

Sample React app - useContext. State data are stored at top or higher level of DOM tree, children components at lower levels access or manipulate them.

Notifications You must be signed in to change notification settings

wangchen-ca/my-react-context

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

My sample React application - my-react-context

To understand/practice React concepts: Context

  • Technical points: define and use Context ( context/data are stored at top or higher level, children components down at different levels of DOM tree access or manipulate the context ).
  • There are 2 context defined:
    • ThemeContext - string, its value can be toggled.
    • UsersContext - stores data of users, more users can be fetched.

The application is created by create-react-app

This project was bootstrapped with Create React App.

Available Scripts

In the project directory, you can run:

npm start

Runs the app in the development mode.
Open http://localhost:3000 to view it in your browser.

About

Sample React app - useContext. State data are stored at top or higher level of DOM tree, children components at lower levels access or manipulate them.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published