I think this kind of misses the point. Even if you understand why JavaScript behaves this way, it doesn't mean that the behavior is sane.
JavaScript without type coercion would have been safer and saner in my opinion.
JavaScript without type coercion would have been safer and saner in my opinion.
Compare with:
> UNIX was not designed to stop its users from doing stupid things, as that would also stop them from doing clever things. — Doug Gwyn
--
†except that you can generate NullPtrException in the pointerless Java. Ask yourself, WAT?
A dull blade on a round onion is not safer than a sharp blade on that onion. Running your hand across a dull blade is safer than running your hand against a sharp blade.
Javascript in a nutshell.
For example, string concatenation could have been handled by a separate operator.