DEV Community

Discussion on: TypeScript is more than you think

Collapse
 
macsikora profile image
Pragmatic Maciej

The question is advantage over what? You need to consider that TypeScript is very pragmatic language in terms of its connection with JavaScript. The data level is not touched, it means that TS has the same primitive types as JS has, but TS makes them explicit.

TypeScript is JavaScript with additional compile time processing of the code. The article focus at this additional type level which is added.

In terms of numbers, JS has primitive number type, TS follows that to be fully compatible. If you want to have language which solves JS issues in numbers you need to take a look at languages which are not compatible with JS. And there are few - Elm, ReasonML, PureScript. There you don't have JS issues.

So TS is natural choice for JS devs, as you know most of the language day one. Its much harder to migrate the whole team to some fully functional language, therefor TS remains a sweet spot of productivity and reliability.