I was playing around today when I noticed that some of my objects in Chrome's console were being displayed as Object instead of the constructor function name.
This was odd, so I boiled it down to the following code:
function Baz() {
this.baz = true;
}
var b = new Baz();
var c = Object.create(b);
console.log(b);
This has to be a Chrome bug right? Is there anyway to get Chrome to correctly report Baz here?
This is important for debugging purposes.
Aucun commentaire:
Enregistrer un commentaire