0.2.2 • Published 4 years ago
ekwal v0.2.2
Compare things
npm install ekwalimport { ekwal } from 'ekwal';
if (ekwal(1,1)) {
console.log('1 equals 1');
}
// NB: it also works with many other thingsAmazing!
Compatibility
Numbers
Support edge cases involving NaN, +/-0 and +/-Infinity values!
ekwal(-Infinity, -Infinity) // => true
ekwal(NaN, NaN) // => true
ekwal(-0, -0) // => true
ekwal(-0, +0) // => falseObjects
ekwal({a: 1}, {a: 1}) // => true
ekwal({a: 1}, {a: 2}) // => false