How To Access Static Variables In Sencha Touch
Posted by admin on
September 8, 2012
Take this class for example where it contains 1 field named domain that contains a url string.
Ext.define('MyProject.myfolder.Test', { statics: { domain: "http://www.cnn.com/" }, });
This Javascript file is located in a folder named myfolder where the view, model and controller folders are.
To access the variable, do the following.
var def = Ext.create('Medworx.model.property.Default'); var defClass = Ext.getClass(def); alert(defClass.domain);









