Comment by semiquaver
2 days ago
For one, you’re not using TypeScript server-side. Whatever execution engine you are using is executing transpiled or JavaScript.
And yeah, I don’t know who in their right mind is starting projects in TS/JS/python these days except when they don’t have an option.
"In their right mind?" I wouldn't start a project in anything other than TypeScript now. My platform is a monorepo across web and native mobile (Expo), and is TypeScript throughout. All my types flow everywhere automatically. Even the shape of a database table is shared with the native app with tRPC. Nothing can break the type contract anywhere. How would you do that with another language?
Absolutely everyone who doesn't work with hardware, or on specific problems, because it's far more popular, easy to hire for, easy to deliver an MVP with and easy to have people jump between frontend and backend with. I'm saying this as someone who specialized in .NET before and now writes Node/TS. I simply grew out of the opinion that language/architecture is everything. When you make a product delivering quicker matters more than choosing a marginally more performant language, unless you're solving a very specific problem that requires that performance. Adding one more server costs less than hiring engineer for a more niche language and if you have the success that requires you to scale up that much, money is probably not the problem anymore. Granted we're in LLM era where everyone can write anything but it's still better to have people vibe in language they actually know, so they understand what's happening. You can always extract services later on and rewrite them in a more performant way, noone's stopping you.
> I don’t know who in their right mind is starting projects in TS/JS/python these days except when they don’t have an option.
I agree, although I would say that for web projects, writing the backend in TS is still a really great option because it means you can use TSX, which has a much better UX than any alternatives. For example https://usefresh.dev/ is much nicer to use than any non-TS options I've found, including Go and Rust where you basically end up using text-based templates along the lines of Jinja.