Hacker News new | ask | show | jobs
by rco8786 3064 days ago
> JS is a big language.

Kind of(maybe). But that's beside the point. Typescript is a separate language that happens to compile to Javascript. The TS team is in no way bound to support every style of programming that Javascript supports (and they don't, just by virtue of having strict typing).

1 comments

They don't have to, but as long as they want to market themselves as a "typed superset of Javascript" (see homepage), they do. For many people, that is the point.
Yep. And this is important, it allows people to move most JS projects incrementally to TS projects. If they fall far behind the features that many JS projects are using, that won't be true anymore, and those people will start using Flow instead (flow.org)
Similarly it is useful for TS to track the Stage 3 proposals of future features and offer them early, as JS users may pick those up with Babel or other polyfills. Typescript's own transpilation behavior of Stage 3 proposal can sometimes be a useful test for the feature while browsers work on their own implementations.