Skip to content

Comment on Ask HN: Is it worth it to invest in learning TypeScript?

Comments

Keep in mind TypeScript is just types, an added compile step, and branding.

The ECMAScript spec will probably supersede TypeScript in the near future anyway. This has happened historically with other dead Javascript dialects (example: when classes were included in ES6).

This will only happen if ECMAScript adopts types, which does not seem to be planned in the near future, afaik. Otherwise I can't see how it would supersede TypeScript, because that's the core reason to use it.

They could add a new directive ala use strict; "use types", that allows one to write types. In the beginning they could be ignored (ala Python's types), but then maybe use them to optimize the jited code, and later catch errors?

Some modern features such as class syntax, arrow functions were championed by coffeescript, and later adapted by TC39. It wouldn't be too far fetched to think that when TC39 will start considering adopting types, they will look similar to what we use nowadays in TypeScript.

If there is an ECMAScript type implementation some day in the future, someone will surely write a transpiler to turn typescript into the new standard.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.