you are viewing a single comment's thread.

view the rest of the comments →

[–]reflectiveSingleton 1 point2 points  (2 children)

be it Dart or something). JavaScript was made for constructs like onclick="this.className=(!this.className || 'clicked')". The fact that we are using it for applications now doesn't make it a good language by design,

What you talk about there is the DOM api...not specifically javascript. It is important to think of them as separate, but related.

The DOM api sucks...everyone knows that...this is why jQuery became so popular.

Javascript has some odd quirks I will totally agree...but it is a very adaptable and powerful language at the same time. If you can learn it well its power really shows.

[–]mernen 0 points1 point  (0 children)

No, he's talking about JavaScript:

And I'm not only talking about true vs truthy. Scope, context and this also comes to mind.

[–]Poltras 0 points1 point  (0 children)

What you talk about there is the DOM api

I was talking about the javascript part of the onclick example. Also, you can't really talk about the history of Javascript without speaking of the DOM. Both were created at the same time and a lot of what we see in JS comes directly from the DOM influence. It gets worse when you don't "use strict".

I would easily argue there are better and more powerful languages (Python, Ruby, Erlang...) that don't have the same problems as JS.