Lesson 4.27mIntermediate10.7k students
Typing external data at the boundary
Data from the network is unknown until you prove otherwise. A runtime schema validates it once and gives you a static type for free.
This lesson sits in TypeScript in Practice, part of TypeScript for Application Developers. It assumes what came before it and leads directly into the next lesson in the module.
In this lesson you will
- Parse unknown input instead of casting it
- Derive a static type from a runtime schema
- Fail loudly at the boundary rather than deep inside
Resources
Your notes for this lesson will appear here.