The fact that {} + [], [] + [], [] + {} are all valid and all give different results ? [1]
The fact that it has some silent error conditions like NaN ?
The fact that, in v8 (which is the most common js engine out there), if you add a comment to a function, it can suddenly start performing poorly ?[0]
I love JS, I really do. Hell, I write nodejs for a living ! I find prototypical inheritance to be an awesome idea. The simplicity, and extensibility of the language is something that I really like from it. But I can see where people hating it are coming from. I wish lua had been used instead of JS.
[0]: https://top.fse.guru/nodejs-a-quick-optimization-advice-7353...
I know a lot of people view using so much tooling as a con of the language, but if you use Babel + Eslint + Flow/Typescript, JavaScript becomes a lot nicer and safer to program in. For small to mid-sized projects, I think JavaScript is pretty great.
Hence the initial comment about putting effort into fixing something fundamentally broken.
Also lets not pretend that having a bunch of quirks like these is exclusive to JS. I'd say there are equally as many ways to shoot yourself in the foot in many other languages. For example, for C++, which isn't necessarily beloved but people don't want to "eradicate" like OP's comment states about JS, you can have an entire talk[0] on the quirks of type deduction.
I think where JavaScript earns its bad reputation isn't necessarily its quirks, but its quirks in combination with a low barrier to entry, lots of beginners, a large community, being a multi-paradigm language, and the fact that most people writing it were forced to write it because it's the language of the web not because they wanted to. All that in combination results in a lot of bad code...but if you take the time to learn it and use a bunch of tooling (which isn't ideal), it's actually quite nice.
Beautiful.
I actually really enjoy node.js and the ecosystem + community surrounding JavaScript. There's seriously a lot of passion and work going in to it.
JavaScript itself though? Horrible. I hate it.
In a year, that's the tally of how terrible or great a language is.
Bad languages don't just make bad choices, they make bad choices and then make different choices for other, similar questions that should be related.
Excerpt: JavaScript is the XML, the Yugo, the Therac-25 of programming languages. The sheer amount of human effort which has been expended working around its fundamental flaws instead of advancing the development of mankind is astounding. The fact that people would take this paragon of wasted opportunity and use it on the server side, where there are so many better alternatives (to a first approximation, every other programming language ever used), is utterly appalling.