PDA

View Full Version : [BETA1] Ext.Loader doesn't load classes



tino7_03
2 Feb 2012, 9:50 AM
In my app.js I wrote:


Ext.application({
config:{
name: 'GpMobile',
namespace: 'GpMobile',
controllers: ['Main','Customers'],
views: ['Viewport','Login','Main','Customers'],
stores:['Customers']
},
launch: function() {
Ext.create('GpMobile.view.Viewport');
}
});




but the app doesn't load the classes.
If I add a class in above "Ext.require" statement the class is loaded...

mitchellsimoens
2 Feb 2012, 12:00 PM
The config object should be used for when you use Ext.define. If you take those things outside the config object then it will work.

edspencer
2 Feb 2012, 3:26 PM
Right - Ext.application creates an instance of Ext.app.Application, not a subclass (that's because you only have one instance of the app running at a time so no need for a subclass)