I can't write Typescript into a browser without cross-compilation and "stripping out types" involves parsing and manipulating code. That's a different language.
There are TS constructs that require compilation into equivalent JS, such as enums and namespaces.
Namespaces are heavily discouraged. Some teams still use enigma but most people in the know us unions of strings.
I know the TS team regrets enums and I have not seen any plans for adding additional keywords that break type stripping.
And thank you for the correction! It was quite a few years ago that I used TypeScript, and I think the landscape was different then.
Making things even fuzzier in my mind, this was an Angular project, and it was hard to keep track of what was Angular and what was TypeScript.
It sounds like people these days actively avoid the parts of TypeScript that require translation into different JS code.
So today, most people and teams avoid the parts of TS that require compilation into different JS, and --erasableSyntaxOnly lets you enforce this, right?