4 ms·
Indeed, the only Typescript feature I can think of that isn't purely for type checking or lifted from ECMAScript is Enums, and Enums have been around forever.
by jsheard 9y ago
Indeed, the only Typescript feature I can think of that isn't purely for type checking or lifted from ECMAScript is Enums, and Enums have been around forever.
- camus2 9y agoWell it has supports for JSX and decorators which AFAIK aren't in the spec yet. It also has a syntax for class mixins without actually doing any desugaring when the code is transpiled. So it's not quite just JS + types.
- jsheard 9y agoAh, I forgot about those. Nonetheless JSX and Decorators were added to the language back in 2015, so they've been sticking strictly to ECMA features for nearly 3 years now.
- namelost 9y agoIt has public, private and protected members (checked at compile-time), which is a bit of a mess because ES is gaining an independent notion of private fields (checked at runtime).