Context API React + Typescript - useContext & useReducer Examples

Context API React + Typescript - useContext & useReducer Examples

Dave Gray via YouTube Direct link

Intro

1 of 11

1 of 11

Intro

Class Central Classrooms beta

YouTube playlists curated by Class Central.

Classroom Contents

Context API React + Typescript - useContext & useReducer Examples

Automatically move to the next video in the Classroom when playback concludes

  1. 1 Intro
  2. 2 Welcome
  3. 3 Starter Code
  4. 4 Extracting initial state & types
  5. 5 useCounterContext hook & type
  6. 6 Create Context with initial context state
  7. 7 Context Provider
  8. 8 useCallback
  9. 9 Applying the Provider
  10. 10 Custom hooks to deliver context
  11. 11 Spreading the ...initState into the Provider parameters is not really necessary. It does help document but really just creates extra boilerplate. You can pull it in from the lexical scope of the Pro…

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.