React Context

https://leanpub.com/code-react-sweetly

How React Context Works

https://leanpub.com/code-react-sweetly

How to Create a Context Object

https://leanpub.com/code-react-sweetly

The syntax of the createContext API

https://leanpub.com/code-react-sweetly

Example: Create a context object

https://leanpub.com/code-react-sweetly

How to Use the Value of a Context Object

https://leanpub.com/code-react-sweetly

The syntax of the useContext Hook

https://leanpub.com/code-react-sweetly

Example: Consume a context object’s value

https://leanpub.com/code-react-sweetly

How to Configure a Parent Component to Provide a Context Value to All Its Descendant Components

https://leanpub.com/code-react-sweetly

The syntax of the context provider

https://leanpub.com/code-react-sweetly

Example: Provide context value to descendant components

https://leanpub.com/code-react-sweetly

How to Override the Context Value Provided to a Child Component

https://leanpub.com/code-react-sweetly

Example: Override a pre-defined context

https://leanpub.com/code-react-sweetly

Example: useContext reads only the providers above its calling component

https://leanpub.com/code-react-sweetly

How to Make a Context Object Available to Multiple Files

https://leanpub.com/code-react-sweetly

1. Create a file for your context objects

https://leanpub.com/code-react-sweetly

2. Create and export your context objects

https://leanpub.com/code-react-sweetly

3. Provide context value to a component tree

https://leanpub.com/code-react-sweetly

4. Consume the context value in a descendant component

https://leanpub.com/code-react-sweetly

5. Create the entry script

https://leanpub.com/code-react-sweetly

How to Create a Dynamic Context Value with React State

https://leanpub.com/code-react-sweetly

Essential Things to Know About React Context

https://leanpub.com/code-react-sweetly

1. Prop drilling

https://leanpub.com/code-react-sweetly

2. children prop

https://leanpub.com/code-react-sweetly