Matt Pocock's Free React TypeScript Tutorial

Matt Pocock's free React TypeScript tutorial teaches typing for hooks, props, events via hands-on exercises. Covers ComponentProps, useRef, and reading React's type defs to debug errors. Bookmark this if your team is adopting TypeScript.
Why it matters
Many teams adopt TypeScript in React projects but struggle with practical patterns like typing forwarded refs, extracting HTML props, or reading React's built-in type definitions to debug cryptic errors. Poor typing leads to verbose code, suppressed errors, or any-type drift that slowly erodes type safety across the codebase. When every engineer invents their own patterns for component props and hook return values, code review becomes a debate about style rather than logic. Having a curated, exercise-based tutorial from a recognized TypeScript educator gives teams a common baseline, reduces code review friction around prop interfaces and hook signatures, and shortens onboarding time for developers joining their first TS React project.
What changed
Matt Pocock released a free React with TypeScript tutorial structured as hands-on exercises using StackBlitz or Gitpod, with an option to clone locally for full VS Code features like jumping to type definitions. The material starts with adding TypeScript to a React project and progresses through typing custom component props, supporting children, and overriding event handlers. It teaches how to leverage TypeScript inference rather than fighting it, and introduces ComponentProps to cleanly extract properties from imported components or HTML DOM elements without verbose manual interfaces. The workshop also covers the APIs and typing for useState, useCallback, useEffect, and other hooks. A reader who completed the exercises noted it replaced their verbose daily-use HTML prop patterns with cleaner techniques, calling it their new go-to recommendation for teams starting with TS and React.
What to watch
If you are onboarding developers to a React TypeScript codebase, consider using the tutorial's exercise structure as a template for internal bootcamps or lunch-and-learn sessions. Watch whether your team's pull requests start using ComponentProps and inference-driven patterns instead of manual prop re-declaration, which is a good signal that the material is sticking. Also note that the tutorial recommends foundational TypeScript knowledge and the Beginner's TypeScript Tutorial as prerequisites, so assess whether junior hires need that prep work first before they dive into the React-specific material.
Interview question
What is the primary risk when React teams adopt TypeScript without standardized prop and hook typing patterns?
- a.StackBlitz and Gitpod environments fail to compile forwarded refs
- b.Code review slows due to style debates and type safety erodes from inconsistent patternsCorrect
- c.ComponentProps forces manual re-declaration of all HTML element props
- d.React's built-in type definitions become incompatible with custom hooks
Why? this is the answer
The card warns that poor typing leads to verbose code, suppressed errors, and code review debates about style rather than logic. Option C is wrong because ComponentProps is introduced to eliminate verbose manual re-declaration, not require it.
Just read this? Test yourself on what you have been reading.
Read the original → totaltypescript.com
- #react
- #typescript
- #tutorials
- #onboarding
- #frontend
Put your scrolling time to good use
Learn one idea, try a quiz and save useful cards for revision. Tezvyn makes it easy to learn and stay current in your tech field, a few minutes at a time.
The iPhone app is on the way
We are building it. Until it lands, nothing here is held back from you: every interview card, your saved cards, streaks and the job board all work in Safari, plus hundreds of free practice quizzes of thirty questions each. Sign in and it all carries over to the app the day it arrives.
Want it as an icon? Tap Share at the bottom of Safari, then Add to Home Screen. It opens full screen and the cards you have read stay available offline.
We are hiring for this. Open roles that interview on react — each one lists the topics its interview covers.
See open roles