Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/sabinadams/react-shared-state-hooks

Example of how to set up a shared state between function components in React using Hooks and the Context API
https://github.com/sabinadams/react-shared-state-hooks

Last synced: 23 days ago
JSON representation

Example of how to set up a shared state between function components in React using Hooks and the Context API

Awesome Lists containing this project

README

        

## Project's Purpose

Explained in my [article on setting up shared state with react hooks and the context API](https://www.sabinthedev.com/shared-state-with-react-hooks-and-context-api/)

Demonstrates one method of sharing state between function components using React's Hooks and Context API.

This project was bootstrapped with [Create React App](https://github.com/facebook/create-react-app).

## Starting the Demo Application

In the project directory, you can run:

### `npm start`

Runs the app in the development mode.

Open [http://localhost:3000](http://localhost:3000) to view it in the browser.

The page will reload if you make edits.

You will also see any lint errors in the console.