Re:JavaScript Equality Minesweeper
by blauditore on Monday September 17, 2018 @07:41AM
(#18004914)
But that's not the same; it's about truthy-ness. E.g. -1 and 1 are both truthy, but not loosely equal.
[ Parent
| on HN ]
Re:JavaScript Equality Minesweeper
by paulintrognon on Monday September 17, 2018 @08:04AM
(#18005044)
That's weird, I would thought that if(value) was the equivalent of if(value == true). Learned something today!
Re:JavaScript Equality Minesweeper
by pythonaut_16 on Monday September 17, 2018 @03:29PM
(#18009168)
You can force cast a boolean by doing if(!!value == true) {}, but at that point you might as well just say if(value)