DEV Community

Discussion on: TypeScript: JavaScript + Types = Awesome Developer Productivity

Collapse
 
simov profile image
simo

First of all thumbs up for mentioning the disadvantages as well. I think we should all try to be a bit more objective in our opinions than just merely following trends.

Well basically all the points you mentioned as advantages doesn't sound like they are worth the trade-off. But that's just me. I can agree only with the:

Great for large-scale applications and teams.

But do we all really work in such conditions? I highly doubt so.

The disadvantages on the other hand surely look like minor things:

  • TypeScript requires a transpilation step
  • You need to learn type annotations syntax and related artifacts
  • It is verbose
  • It sometimes falls out of line with the ECMAScript standard

But that's what hampers your productivity and slows you down.

The whole point of the dynamic languages to exist is to allow faster prototyping.

And the first thing we think about prototyping is the initial phase of a project.

But (micro) prototyping happens all the time:

The act of human being sitting behind a keyboard and writing commands to a computer to execute is an act of prototyping.


Anyway, apart from probably being a good fit for really large projects, TypeScript also helps to alleviate the fact that the majority of the web developers had started their careers using dynamically typed languages, and know nothing about types.

Types are always there, but the dynamic languages, like JavaScript, require a bit more diligence on the developer side, and a prior knowledge of typed languages.