Narrowing & Type Guards
← TypeScript course — Chapter 4 of 5
How TypeScript narrows types with typeof, instanceof and in, discriminated unions, type predicates, and when (not) to use as.
~~~
Your score — Narrowing & Type Guards
/ (%)
~~~
Learn more
These quizzes are based on tutorials published on this site. Go deeper on Narrowing & Type Guards:
~~~
About this course
This is a chapter of the free TypeScript quiz course. Answer each question, get immediate feedback with an explanation, and move on. Your progress is saved in your browser — nothing leaves your machine.