function Class() {}
actually
Class.prototype = new Object();
Class.prototype.constructor = Class;
var instance = new Class();
actually
var instance = new Object();
instance.__proto__ = Class.prototype
Class.call(instance);
function BaseClass() {}
function Class() {}
Class.prototype = new BaseClass()
// true, because `new Class().__proto__ === Class.prototype`
new Class() instanceof Class
// true, because `new Class().__proto__.__proto__ === BaseClass.prototype`
new Class() instanceof BaseClass
Class.prototype.constructor === BaseClass
// we should better set constructor back to Class
Class.prototype.constructor = Class
The Class.prototype.constructor
property makes no practical difference internally. It's only difference when our code explicitly uses it.