-
TypeScript is a superset of JavaScript created by Microsoft.
-
Allows static strick typing
-
Extra features - interfaces, enums, tuples, generics
-
Support modern features (arrow functions, let, const)
-
Based on the .NET harmony specification
- Not suitable for large applications
- Lacks strong typing
- Weird inheritance, unfamiliar syntax
- Only errors during runtime
- Suffers type coercion
- TypeScript = JavaScript
- Compiles to JavaScript - run everywhere
- Familiar OO programming
- New Features work everywhere
- Install Node.js in your machine
- Install TypeScript compiler using
- npm
npm i -g typescript
- yarn
yarn global add typescript
- npm