I have created the class in Ext JS 4, and now I want to extend that in another class. I use extend properties, to extend the class. But I am not able to extend the class. Do I want to use require to include the class file. But I keep both the files in the same directory.
I have created the class in Ext JS 4, and now I want to
Share
Define source paths for ExtJS to locate your source files.
Then define
Ext.requireorrequiressection in subclass to enable automatic path resolution.Read this link for more info.
Example
Base class: file located at folder
root/view/common/Picker.jsSub class: file located at folder
root/view/selection/DriverTreeCombo.jsI have namespace as RL.xxx.xxx and RL is supposed to be the
rootfolder. Now I can define Loader configuration as belowLoader configuration should be set before ‘Ext.onReady(…)’ function call. Going through examples folder in ExtJS package would help you to see how this is done.
Further reading: