Think you know TypeScript? Think again.
summary
Claims concrete tactics: replace any with unknown and add explicit guards, write type predicates for narrowing so variables truly become strings or numbers, use discriminated unions with an exhaustive never check to catch added variants, apply utility types (Parameters/ReturnType, template-literal keys) and recursive types to generate safe translation keys, extend globals via interface merging (window), and wire API schemas with trpc codegen or OpenAPI+zod so CI fails on breaking contract before runtime.
AI-written summary · about
chapters (16)
- 0:00TypeScript journey introduction
- 1:06Basic types to type safety pitfalls
- 2:57Unknown types and type guards
- 4:04Type predicates and narrowing
- 5:31Discriminated unions and checks
- 7:40Utility types for safer code
- 9:07String manipulation with types
- 10:12Recursive types for nesting
- 11:58Interfaces vs types deep dive
- 13:45Interface merging use cases
- 15:34React props inconsistencies
- 16:16Sharing types frontend/backend
- 17:42TRPC and GraphQL type sharing
- 18:45Code generation and OpenAPI
- 20:14CI checks for type safety
- 20:55TypeScript improves workflow
related talks
24mTypeScript for JavaScripties
21mThe long-tail of type safety
21mThe long-tail of type safety
01h 01mDeconstructing TypeScript’s Type System
21mBeyond Type Checking Building Bulletproof TypseScript Applications
34mNot Your Uncle’s Clean Code (TypeScript Edition)
30mRust-Inspired Typescript
44mA Deep Dive Into Advanced TypeScript - A Live Coding Expedition
