Every valid TypeScript program (with correct config) becomes JavaScript. Types exist only at compile time—they are erased in output.
Syntax you keep
Variables, functions, classes, modules, async/await—all familiar. TypeScript adds:
- Type annotations:
const n: number = 1 - Interfaces and type aliases
- Generics, enums, access modifiers on classes
When to stay in JavaScript
Small scripts, quick prototypes, or environments without a compile step may stay JS. This track assumes you want maintainable app code where types pay off.
Practice: Apply ts-vs-javascript in the playground, then explain ts vs javascript in one sentence without looking at notes.