Is there a good reason browsers could and or should not support ts out of the box? I think even node does to some extend.
Anyway another thing that kept bugging me when reading this is that web apps and development and performance constraints can be so vastly different that I am not sure this pattern always holds up. What if you have an app that depends on a ton of global state, what if you need web sockets, what if you need a highly dynamic form with partial validation derived from a schema that your drizzle definition spat out. And 2 junior devs that benefit from end 2 end type safety and working in Typescript alone to be productive. Add syncing across tabs, offline first requirements, multiplayer rich text editing, sophisticated auth, caching, accessibility constraints, end 2 end monitoring and logging with open telemetry, animated page transitions scroll timeline animations, pdf generation of certain views and a design team breathing down your neck that has a thousand different extra bells and whistles it wants that are impossible to represent and maintain with tailwind alone. And then the marketing department comes around and wants to track everything, inject their A/B testing framework, wants dynamically updated translations without forgoing SSR and SEO benefits and all of that has to run on a 8€/month Hetzner VPS.
I understand that if you work on software that only needs a handful of those things you can get away with a better stack than what the author seems to loathe. But it you work on a large enough application, then you can’t escape complexity, even if you find some of it remedied by a well suited tech stack.
> Is there a good reason browsers could and or should not support ts out of the box?
Because it’s a Microsoft product and Microsoft still follows Embrace, Extend, Extinguish process. Once every browser supports TS, what prevents Microsoft from revving TS with a license change? Who’s going to take over the TS fork?
I would guess that the big reason is Microsoft is the owner of Typescript. Apple, Google, and Mozilla probably don't want to be tied to the whims of someone else's language specification. It's the same reason Dart isn't a browser language, NaCl doesn't exist anymore, ASM.js development wasn't widely adopted but sowed the seeds for WASM.
Web standards get worked on by committee where those four companies each have some pull, and standards are voted on.
Node's typescript support is by default just stripping all of the type information out of the source text. There is experimental support for some transformations behind a flag.
https://nodejs.org/api/typescript.html#full-typescript-suppo...