I tried this, self, Class name.
Example:
statics: {
A: 'something',
B: className.A
}
I tried this, self, Class name.
Example:
statics: {
A: 'something',
B: className.A
}
How about this.self?
EDIT: Sorry, slightly misunderstood the question. You're right, there seems to be no way of doing this because there is no object to work with at the time when the statics are evaluated. You can reference static variables in static functions though, maybe that helps:
and then laterCode:statics : { A : 'something', B : function() { return this.A; } }
Code:console.log(My.cool.Class.B());
Code:Ext.define('MyClass',{ statics: (function(){ var str="something"; return { A: str, B: str }; })() })
I write English by translator.
Well, I guess there is a way to do this after all.
Nice one haduki