Docs
/
TypeScript
TypeScript — Complete Learning Roadmap
Phase 1: Foundations (Topics 1–5)
| # | Topic | Key Concepts |
|---|---|---|
| 01 | Setup & Configuration | tsc, tsconfig.json, strict mode, target/module, watch mode |
| 02 | Primitive Types & Special Types | string, number, boolean, any, unknown, void, never, null, undefined, bigint, symbol |
| 03 | Arrays, Tuples & Enums | typed arrays, readonly arrays, tuples, labeled tuples, numeric/string/const enums |
| 04 | Type Inference & Annotations | implicit inference, contextual typing, const assertions, satisfies operator |
| 05 | Union & Intersection Types | union narrowing, literal types, intersection merging, distributive behavior |
Phase 2: Functions & Objects (Topics 6–10)
| # | Topic | Key Concepts |
|---|---|---|
| 06 | Functions & Overloads | parameter types, return types, optional/default params, rest params, overloads, this parameter |
| 07 | Objects & Interfaces | object types, optional properties, readonly, index signatures, extending interfaces, interface merging |
| 08 | Type Aliases vs Interfaces | when to use each, computed properties, mapped types, declaration merging, practical guidelines |
| 09 | Type Assertions & Narrowing | as keyword, non-null assertion, typeof guards, instanceof, in operator, custom type guards, assertion functions |
| 10 | Classes & Access Modifiers | public, private, protected, readonly, abstract classes, implements, static members, parameter properties |
Phase 3: Generics & Advanced Types (Topics 11–15)
| # | Topic | Key Concepts |
|---|---|---|
| 11 | Generics | generic functions, generic interfaces, generic classes, constraints (extends), default type params, multiple type params |
| 12 | Utility Types | Partial, Required, Readonly, Pick, Omit, Record, Exclude, Extract, NonNullable, ReturnType, Parameters, Awaited |
| 13 | Mapped Types & Template Literal Types | key remapping, modifier removal, template literal unions, intrinsic string types, recursive types |
| 14 | Conditional Types & infer | extends keyword, infer extraction, distributive conditionals, nested conditionals, type-level programming |
| 15 | Discriminated Unions & Exhaustive Checks | tagged unions, switch narrowing, never for exhaustiveness, pattern matching, state machines |
Phase 4: Modules & Declarations (Topics 16–18)
| # | Topic | Key Concepts |
|---|---|---|
| 16 | Modules & Namespaces | ESM import/export, re-exports, barrel files, dynamic import, namespaces, module augmentation |
| 17 | Declaration Files & Ambient Types | .d.ts files, declare keyword, @types packages, global augmentation, module declarations, triple-slash directives |
| 18 | Decorators | class decorators, method decorators, property decorators, parameter decorators, decorator factories, metadata |
Phase 5: Real-World Patterns (Topics 19–20)
| # | Topic | Key Concepts |
|---|---|---|
| 19 | Error Handling Patterns | Result/Either type, custom error classes, type-safe try/catch, error hierarchies, exhaustive error handling |
| 20 | Advanced Patterns | branded/opaque types, builder pattern, type-safe event emitter, phantom types, variance, recursive types, HKT simulation |
Suggested Learning Path
Phase 1 (Foundations) ──▶ Phase 2 (Functions & Objects) ──▶ Phase 3 (Generics & Advanced)
│
Phase 4 (Modules) ◀───────┘
│
Phase 5 (Patterns) ◀───────┘
Format: Each topic folder contains a README.md (concepts + notes) and a .ts code file (10–15+ commented examples).