That's why I'm a big proponent of a new browser language (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, and "just use that instead of this" is a poor defense for fundamental flaws. And I'm not only talking about true vs truthy. Scope, context and this also comes to mind.
-2
u/[deleted] Mar 26 '14
== is one of those easy targets for people who hate JavaScript's design.
In actual reality, == just isn't a problem. It can only cause bugs if your code is already poorly designed, and === exists.