// === says +0 and -0 are equal, and NaN is never equal to itself console.log(0 === -0); console.log(NaN === NaN); // Object.is treats these the other way console.log(Object.is(0, -0)); console.log(Object.is(NaN, NaN));
special cases for -0 and NaN