Why isn't {} the same as a new Obect()

Viewed 14

Code:

var object = new Object()
console.log(typeof(object), typeof({}))
console.log(object == {}, object != {})

Output:

object object
false true

Why is {} not the same as a new Object(), even though both output object when doing typeof()?

0 Answers
Related