Exercise #63: Type Predicates And Classes
Advanced Patterns ยท 04-classes
Go back to exercises
Open in TypeScript Playground
Goal
Goal: Turn `isInvalid` into a type predicate that narrows `this.error` when the form is invalid.
Check Solution
Run "Check Solution" to validate your code in the browser.