TSTypeScript · Lesson 1 of 10
Hello, TypeScript!
TypeScript is a superset of JavaScript. Every .js file is valid TypeScript — you just get to add types on top. Start simple, add types where they help.
TypeScript files end in .ts. The TypeScript compiler (tsc) transpiles them to plain JavaScript. Alternatively, ts-node runs TypeScript directly for scripts and development.
◆ Note
TypeScript types only exist at compile time. Once compiled to JavaScript, all type information is erased — it adds zero runtime overhead. The types are purely for you, your editor, and the compiler.
TypeScript types only exist at compile time. Once compiled to JavaScript, all type information is erased — it adds zero runtime overhead. The types are purely for you, your editor, and the compiler.