Compiling TypeScript to JavaScript
Understand the TypeScript compiler and its output.
Welcome
TypeScript cannot run directly in Node.js or the browser. It must be compiled to JavaScript first. In this lesson you'll learn how the TypeScript compiler works.
Installing the TypeScript Compiler
Install TypeScript as a dev dependency in your project. The `tsc` command becomes available in your local scripts after installation.
npm install --save-dev typescript
npx tsc --versionAll lessons in this course
- JavaScript Pain Points: Runtime Bugs
- What TypeScript Adds to JavaScript
- Compiling TypeScript to JavaScript
- When to Use TypeScript in Your Projects