Begin by using the official TypeScript Playground – no installation needed. Write and run your first TypeScript code:
const message: string = "Hello TypeScript!";
console.log(message);
Experiment with errors, like assigning a number to a string, to see type checking in action. Optionally, install locally:
- Install Node.js from nodejs.org.
- Run
npm install -D typescript@latest (current version 5.9.3).3. Create tsconfig.json with tsc --init.
Read TypeScript in 5 Minutes.