Sure! For starters, you can write
if (foo == null) { ... }
Because `undefined` gets coerced to `null`, it saves you from writing: if (foo === null || foo === undefined) { ... }
And, because it's shorter, it's even allowed by [some JS linters](https://standardjs.com/).There you have your JS ninja trick to handle two distinct null types^TM .
1. I was making a generalized statement around JS, not specifically '=='. That's a misinterpretation of my statement.
>"my programming language is perfect"
2. I did not say JavaScript is perfect. That's a misinterpretation of my statement.
>"if you don't like it you're just too dumb to get it"
3. I did not say "if you don't like you're just too dumb." That's a misinterpretation of my statement.
JavaScript really _isn't_ all that expressive.
I just don't get it. What's wrong with expressing my love for a language that I love? I am not even asking for anyone to switch to JS, just expressing my feel.
Thanks for pointing that out.
I think might be due to the downvotes somehow. It makes you wonder if you did something wrongly or it is simply people disagreeing with you.