Coding courseTypeScript
TypeScript for beginners
16 short lessons: a minute of theory, a task in the browser, the result right away.
16 lessons
Lessons
- Lesson 1What is TypeScript? Your first program
- Lesson 2Basic types and annotations
- Lesson 3Arrays and tuples
- Lesson 4Functions: parameters and return types
- Lesson 5Objects and interfaces
- Lesson 6Type aliases and union types
- Lesson 7Literal types and narrowing
- Lesson 8Generics
- Lesson 9Enums vs union types
- Lesson 10Classes and access modifiers
- Lesson 11readonly and utility types
- Lesson 12Type guards: typeof, in, instanceof
- Lesson 13Discriminated unions
- Lesson 14Modules and namespaces: organising code
- Lesson 15async/await and typed Promises
- Lesson 16Mini project: a typed task tracker
Questions
Why learn TypeScript?
In GitHub's Octoverse 2024 report TypeScript was the third most used language on GitHub, after Python and JavaScript. In Octoverse 2025 GitHub reported that TypeScript took first place in August 2025. Source: https://github.blog/news-insights/octoverse/octoverse-2024/
Do I need to know JavaScript first?
The basics are enough: variables, functions, conditions and loops. TypeScript is JavaScript with types, so the syntax will feel familiar, and everything new is explained as you go.
What do I need to install?
Nothing: the code runs right on the lesson page. For your own projects you will later need Node.js and the typescript package from npm; npx tsc then checks the types and builds JavaScript.
How are tasks checked?
Your code runs, and whatever it prints with console.log is compared with the expected output. TypeScript also checks the types: a task counts once there are no type errors. Stuck? Open the hint or the solution.
Is the course free? What is it based on?
Yes, every lesson is free. The curriculum draws on open GitHub projects: the TypeScript Handbook, TypeScript Deep Dive, The Concise TypeScript Book and type-challenges. We wrote the explanations and tasks ourselves.