What You'll Learn in TypeScript
Beginner
Introduction
Learn what TypeScript is and why it exists.
Setup
Install TypeScript and configure tsconfig.json.
Basic Types
string, number, boolean, and other primitive types.
Arrays & Tuples
Type arrays and fixed-length, fixed-type tuples.
Enums
Define a set of named constants.
any, unknown, never & void
Understand TypeScript’s special types.
Type Inference
How TypeScript infers types automatically.
Type Aliases
Create reusable names for any type.
Interfaces
Describe the shape of objects with interfaces.
Function Types
Type function parameters, return values, and overloads.
Union & Intersection Types
Combine types with | and &.
Literal Types
Restrict a value to specific literal values.
Intermediate
Object Types
Type object shapes, nested objects, and index signatures.
Optional & Readonly Properties
Mark properties as optional or immutable.
Type Assertions
Override TypeScript’s inferred type with as.
Classes
Typed classes, constructors, and inheritance.
Access Modifiers
public, private, protected, and readonly members.
Interfaces vs Type Aliases
Know when to use each one.
Generics
Write reusable, type-safe functions and components.
Generic Constraints
Restrict generics with extends.
Type Narrowing
Narrow union types with type guards.
Advanced
Utility Types
Partial, Pick, Omit, Record, and more.
Mapped Types
Transform existing types into new ones.
Conditional Types
Choose a type based on a condition.
Custom Type Guards
Write your own type predicate functions.
Modules
Import and export types and values across files.
Declaration Files
Describe the types of plain JavaScript with .d.ts files.
Decorators
Annotate and modify classes and members.
tsconfig Deep Dive
Understand the most important compiler options.
Best Practices
Write maintainable, strict TypeScript.
Finished Learning TypeScript?
Test your knowledge with MCQs, output-based questions, and interview questions.