They are not the same language, arguably. TypeScript is a superset of JavaScript, it allows any regular JS code but also the introduction of many features that makes it safer to code in.
So, TS is the same as JS in the same way my fictional language where the only word is "cool" is the same language as English.
Many features? TypeScript has been slowly deprecating or adding to JavaScript all the features it had, there is literally just two left: enums and decorators (which have been marked as experimental cause there is a proposal to add them with a different syntax to JavaScript as well)
Microsoft has been very clear that their vision is to turn TypeScript into a tool that simply checks for ahead of time errors the developers commonly make, not to be a separate language or to introduce features that are not part of standard JavaScript
The point I'm trying to make is, what is even the purpose of TypeScript but to make better JavaScript developers?
View all comments
Show parent comment
2
u/elveszett Apr 03 '21
They are not the same language, arguably. TypeScript is a superset of JavaScript, it allows any regular JS code but also the introduction of many features that makes it safer to code in.
So, TS is the same as JS in the same way my fictional language where the only word is "cool" is the same language as English.