Hi, you are overriding constructor by
prototype = {}.. Look
var Superclass = function (property1, property2) {
this.property1 = property1;
this.property2 = property2;
};
// this overrides constructor Superclass.prototype = {};
// this is how Google Closure methods should be defined
Superclass.prototype.getProperty1 = function () {
return this.property1;
};
Superclass.prototype.getProperty2 = function () {
return this.property2;
};
var Subclass = function () {
goog.base(this, "one", "two");
};
goog.inherits(Subclass, Superclass);
// this would fix it, but better to be unfixed
// Superclass.prototype.constructor = Superclass;
var s = new Subclass();
alert(s.getProperty1());
All methods should be defined directly on prototype object
prototype.methodA = fn..
(inherits method can be fixed, but better is not to allow override
prototype, because subclasses must mix methods anyway)