Skip to content Skip to sidebar Skip to footer

Why Is `object() === New Object()` Equal To `false`?

Why it returns false? let a = new Object() let b = Object() console.log(a) // {} console.log(b) // {} console.log(a===b) // false I checked a proto of a and b too and it is the sa

Solution 1:

Instance of objects are not the same even:

let a = new Object();
let b = new Object();
console.log(a===b) // false

Post a Comment for "Why Is `object() === New Object()` Equal To `false`?"