TypeScript Core (Interview Prep)
A structured roadmap of the TypeScript fundamentals that matter most in frontend interviews. Start top-to-bottom.
Series: TypeScript Core
Start here
TypeScript: types vs interfaces (When to Use Which)
A deep, interview-ready guide to TypeScript types vs interfaces: extension, unions, intersections, declaration merging, and practical patterns for real codebases.
Roadmap (30)
Browse all TypeScript Core posts →- 1
TypeScript: types vs interfaces (When to Use Which)
A deep, interview-ready guide to TypeScript types vs interfaces: extension, unions, intersections, declaration merging, and practical patterns for real codebases.
2 min read - 2
TypeScript Generics: Basics, Constraints, and Real Patterns
A deep, interview-ready guide to TypeScript generics: why they exist, how inference works, constraints (extends), default generics, and practical examples used in real codebases.
2 min read - 3
TypeScript Narrowing & Discriminated Unions (Interview-Ready)
A deep, interview-ready guide to narrowing in TypeScript: typeof, in, instanceof, user-defined type guards, and discriminated unions for safe, expressive code.
1 min read - 4
TypeScript Utility Types: Pick, Omit, Partial, Record (Practical Guide)
A deep, interview-ready guide to TypeScript utility types: Pick/Omit/Partial/Required/Readonly/Record, common patterns, and how to avoid over-complicating types.
1 min read - 5
any vs unknown vs never (Interview-Ready)
How to choose any/unknown/never, why unknown is safer, and how never appears in narrowing and exhaustive checks.
2 min read - 6
Type Guards & Narrowing Patterns
How narrowing works in TypeScript: typeof/in, custom type guards, assertion functions, and practical patterns for safer code.
1 min read - 7
The `satisfies` Operator (Why It’s a Big Deal)
How `satisfies` helps validate shapes without losing literal types, and why it often beats `as const` and type annotations.
1 min read - 8
Conditional Types + infer (Interview Essentials)
Understand conditional types, infer, and how TypeScript extracts types from functions/promises/arrays.
1 min read - 9
Declaration Merging & Module Augmentation
How TypeScript merges interfaces, augments modules (like Express/NextAuth), and why this matters in real codebases.
2 min read - 10
tsconfig.json: The Settings That Matter
A practical guide to TS compiler options interviewers ask about: strict, noImplicitAny, lib, moduleResolution, jsx, and incremental builds.
4 min read - 11
Enums vs Union Types (and const enums)
When to use enums, when to prefer string unions, and what const enums change.
1 min read - 12
Typing React Components in TypeScript (Practical Patterns)
Props, children, event handlers, generics in components, and common TS + React pitfalls interviewers ask about.
2 min read - 13
Mapped Types, keyof, and Template Literal Types (Interview-Ready)
How keyof + mapped types work, and how template literal types unlock powerful typed APIs.
2 min read - 14
Advanced Generics: Overloads, Inference Tricks, and Variance
Interview-focused advanced generics: overloads, inference patterns, variance basics, and designing ergonomic typed APIs.
2 min read - 15
Type-Level Testing & API Design Patterns
How to validate TypeScript types, design safer APIs, and avoid unsafe assertions—interview-ready patterns.
2 min read - 16
ESM vs CJS in TypeScript (Interop Without Tears)
Understand what TypeScript emits vs what Node runs, and how to avoid the common import/export traps in real codebases.
4 min read - 17
package.json exports + Types: Designing a Clean Public API
How to structure multi-entry TypeScript packages with package.json exports, prevent deep imports, and ship correct .d.ts for consumers.
2 min read - 18
moduleResolution: NodeNext vs Bundler (and Why It Breaks Builds)
How TypeScript resolves imports in modern toolchains, when to use NodeNext vs bundler, and how flags like verbatimModuleSyntax affect real projects.
3 min read - 19
Path Aliases That Don’t Break Production (@/ Without Regret)
How to use tsconfig paths safely across Next.js, bundlers, Node scripts, and tsc builds—without ‘works locally, fails in prod’.
3 min read - 20
Conditional Exports (node/browser) + Correct Types
How to publish different entry points for Node vs browser (or edge) using package.json exports conditions, without breaking TypeScript consumers.
3 min read - 21
Strongly Typed pipe()/compose() (Variadic Tuples vs Overloads)
How to type function pipelines like a library author: overloads, variadic tuples, inference boundaries, and what interviewers really want to see.
2 min read - 22
Template Literal Types for Safe Routes, Events, and Keys
Use template literal types to make strings type-safe: route patterns, event names, CSS variables, and i18n keys—with realistic examples.
2 min read - 23
Branded Types: Safer IDs, Money, and Domain Values
Use branded (nominal-ish) types to prevent mixing IDs and domain values, and learn safer alternatives to ‘just cast it’.
2 min read - 24
unknown → Safe Types: Runtime Validation Patterns
Stop lying with `as`. Learn production patterns to convert unknown data (fetch, localStorage, env) into safe TypeScript types with guards and assertions.
2 min read - 25
satisfies: Enforce Shape Without Losing Literal Types
Use the satisfies operator to validate objects (routes, feature flags, configs) while preserving literals for great inference and fewer casts.
2 min read - 26
Bug-Catching TS Flags: noUncheckedIndexedAccess & exactOptionalPropertyTypes
Two TypeScript options that catch real production bugs: safer indexing and optional properties that behave like you think.
2 min read - 27
Typed Forms Without Pain (Mapped Types + Generic Helpers)
A production-friendly pattern to type form values, errors, and validators using mapped types—no giant unions, no any.
2 min read - 28
Polymorphic React Components (the 'as' Prop) with Type Safety
How to type a polymorphic component like a design-system author: correct props, correct refs, and zero unsafe casts.
2 min read - 29
Type-Level Testing + Public API Design (Library Author Mindset)
How to keep TypeScript APIs stable: test your types, design exports intentionally, and avoid leaking internals that you can’t maintain.
2 min read - 30
Scaling TypeScript: Project References, Composite Builds, and Fast CI
How large TypeScript codebases stay fast: project references, composite builds, incremental compilation, and clean boundaries.
2 min read