Hacker News new | ask | show | jobs
by offtop5 1838 days ago
I've built multiple JavaScript project at scale, and I would never trust it over java or C sharp. JavaScript allows you to make way too many mistakes.

I do think Dart is the best of both worlds though. Having real types, not hacked together typescript stuff is very good. That's the other thing the nodejs ecosystem feels like a bunch of duct tape slap together again and again

1 comments

What do Java or C# offer that Typescript cannot offer? Genuine curiosity as I’m not quite sure myself.

It seems, through my experience, that Typescript isn’t “hacked together” as you imply. It’s just another Type-system, just like Java or C#’s?

Java's thread support is as correct as can be and provides sufficient primitives that if you can't use a multi-core machine efficiently it is your fault, not the fault of your language and runtime. Same for C#.

This holds for "high-level" resources.Wwith the multi-threaded model you can share a single large immutable configuration object between all threads, or pass a database connection from one thread to another with close-to-zero cost.

Java and C# languages are a bit more CPU efficient. In the cloud computing world a website publisher pays real money for server CPU and RAM but can use the CPU and RAM on your computer or phone for free.

Babble.

The weird transpilation system constantly breaks. I guess maybe one day they'll be better tooling around this, but it's not there yet. And I've worked with node in some capacity since 2013, things always feel fragmented and broken

Have you tried Vite[0]? It's an amazing dev server I learned about in an HN post. It does a fabulous job of TS transpilation and has many other niceties for dev work.

BTW, with modern browsers, why would you need to transpile JS (as opposed to TS)?

[0] https://vitejs.dev/

> What do Java or C# offer that Typescript cannot offer? Genuine curiosity as I’m not quite sure myself.

A vast ecosystem of battle-tested libraries for one.