Hacker News new | ask | show | jobs
by Jasp3r 1487 days ago
The whole issue of JavaScript is that the standard library is worthless, so people have to write additions to keep yourself sane as a developer. This makes it seem that there are 5 billion ways to do something, because there are.

Just use TypeScript, it will fix all the issues you have with the language itself. Typing + build time errors + import/export syntax. If you want to run some this in the browser, and don't use Vue or React, it will still require manual work to setup webpack + babel

I still hear this hypetrain argument a lot, but only on hacker news. This hypetrain you have been talking about is however not the case anymore. JavaScript + TypeScript have been stable for the last 3 to 5 years, the only big change in FrontEnd development was that people have been pivoting to server side rendering.

As a fullstack dev, the most hypetrain stuff I see is with infrastructure. Docker? Kubernetes? Terraform? Combined with 15 different ways to do the same thing in AWS but worse, no thank you.

3 comments

Typescript doesn't solve any of the mentioned issues. You can't use CommonJS modules if you are targeting ES6+. And you can't use ES6 modules if you are targeting CommonJS. The only thing really useful about Typescript is types + generics (to some extent).

If you install any library that's either only ESM or CommonJS, you can't run your program. It simply doesn't work.

I have never had this issue in my life. If you have issues with module bundling, use a module bundler.
I rarely, if ever, have to reach for anything outside of the standard library for computation/algorithms. ES6 added most, if not all, the building blocks to build 99% of the computation you'll ever need. What's missing that you'd deem as worthless?
> ES6 added most, if not all, the building blocks to build 99% of the computation you'll ever need. What's missing that you'd deem as worthless?

Not the same person, but date/time manipulation is one area I've encountered that's incredibly frustrating (especially when timezones are involved) without libraries like moment. Cross-browser functionality only compounds the issues.

Ah yes, I'd agree with that. To be fair though as well, many languages have struggled there; re: Java/Joda/Java 8's java.time
Yea, TypeScript makes things easier. I think it's _also_ way better than plain JavaScript, but the simpler tooling is a huge value add on its own