Comment by wpollock
1 day ago
> Because "it doesn't exist". It's just a layer on top of js, ...
C++ was originally a layer on top of C. The first C++ compiler, "cfront" was actually a transpiler to C.
There is nothing preventing TypeScript from becoming "native" in a similar way.
Typescript is only a linter, except for types annotations it is regular JS, quite different from C with Classes.
If you are going to mention enum and namespaces, the team considers them a design error, and only keeps them around due to backwards compatibility.
It doesn't make any sense tho. Typescript is nothing much to do with runtime. It's a build/dev concern. To get JS from TS you're mostly removing the type annotations.
Theres no reason to ship TS to an end user browser.
> Theres no reason to ship TS to an end user browser.
As things are now, developers write code in TypeScript, then debug and update code in Javascript. It might not be much of a reason, but a single language throughout is surely easier on developers and maintainers.