2 ms·
> What do you mean by weird quirks ? - undefined vs null vs empty - the pile of weirdness that is == - the other pile of weirdness that is implicit truthines
by _bxg1 8y ago
> What do you mean by weird quirks ?
- undefined vs null vs empty
- the pile of weirdness that is ==
- the other pile of weirdness that is implicit truthiness/falsyness
- NaN's many fun qualities
https://www.destroyallsoftware.com/talks/wat https://www.destroyallsoftware.com/talks/wat
- z3t4 8y agoOhh yeh, I think the equality table is just something you have to learn, like a chemist learn the periodic table. I make use of null==undefined a lot and prefer it over thruthy/falsy. I try to avoid NaN but sometimes use isNaN(nr)