JavaScript is a victim of its own popularity. It was originally meant to be scripting glue to do little actions in the browser while the real work was done in Java (LiveConnect) apps. But Java got jettisoned, JavaScript became more important and became the thing we love and hate today.
Most of the examples listed there are issues that don’t affect real applications. It’s just garbage code, so the output ends up being garbage too. Programmers don’t write code like that, unless they are doing it as a joke. A few of those examples can be real issues sometimes, but they are not that big of a deal to an experienced JavaScript programmer.
but they are not that big of a deal to an experienced JavaScript programmer.
A well-designed language wouldn’t require “experience” for stupid gotchas like these to not be that big of a deal in the first place.
After all, I’m sure a sufficiently “experienced programmer” could adapt to anything up to and including fucking Malbolge if necessary, but that doesn’t mean it’s equal to a language that’s actually good.
Differences in quality between languages are real, and Javascript is closer to the bad end of that spectrum.
Every language is gonna be weird if you don’t know it well enough. In Lua arrays start with index 1. Is it weird? Yes. But do Lua programmers care? Probably not.
The stuff that many people say is bad in JavaScript is usually irrelevant. That doesn’t mean that there aren’t bad parts like the Date api or the lack of types is a flaw to many people. Those are actually important issues. In this case they are solved by libraries and TypeScript. The performance is also a problem in some applications. Which is why there is WebAssembly, which can help in some cases.
So there are plenty of real flaws that can be pointed out, but you have to know the language to be able to tell what actually matters. To me it doesn’t seem any worse than any other modern language.
> someone like Brendan Eich who should know better turn to the dark side
LOL, he inflicted Javascript upon the world. He never knew better and was always on the dark side.
JavaScript is a victim of its own popularity. It was originally meant to be scripting glue to do little actions in the browser while the real work was done in Java (LiveConnect) apps. But Java got jettisoned, JavaScript became more important and became the thing we love and hate today.
No, that’s not the issue. If Javascript were well-designed we wouldn’t hate it, but it wasn’t.
Most of the examples listed there are issues that don’t affect real applications. It’s just garbage code, so the output ends up being garbage too. Programmers don’t write code like that, unless they are doing it as a joke. A few of those examples can be real issues sometimes, but they are not that big of a deal to an experienced JavaScript programmer.
It’s an imperfect language like any other.
A well-designed language wouldn’t require “experience” for stupid gotchas like these to not be that big of a deal in the first place.
After all, I’m sure a sufficiently “experienced programmer” could adapt to anything up to and including fucking Malbolge if necessary, but that doesn’t mean it’s equal to a language that’s actually good.
Differences in quality between languages are real, and Javascript is closer to the bad end of that spectrum.
Every language is gonna be weird if you don’t know it well enough. In Lua arrays start with index 1. Is it weird? Yes. But do Lua programmers care? Probably not.
The stuff that many people say is bad in JavaScript is usually irrelevant. That doesn’t mean that there aren’t bad parts like the Date api or the lack of types is a flaw to many people. Those are actually important issues. In this case they are solved by libraries and TypeScript. The performance is also a problem in some applications. Which is why there is WebAssembly, which can help in some cases.
So there are plenty of real flaws that can be pointed out, but you have to know the language to be able to tell what actually matters. To me it doesn’t seem any worse than any other modern language.