Closed ghost closed 11 years ago
Have this same problem. Any solutions?
you have to do it like this:
var View = klass({
initialize: function (a, b) {
this.a = a
this.b = b
}
});
var MenuView = View.extend({
initialize: function () {
this.supr('val1', 'val2');
}
});
See "Object Literals" https://github.com/ded/klass#object-literals
Given a super class:
I can't find a way to set the values of templateId and containerId from within a subclass constructor and be able to use them from the superclass constructor:
Instead of being able to do initialization logic inside of View's constructor, I have to wait until after MenuView is instantiated, and then manually call my own initialize method after the constructor chain executes.