Quote Originally Posted by Stju View Post
Yes, this is the correct way.
Compare with the example from docs:

http://docs.sencha.com/touch/2-0/#!/api/Ext.data.Model
Hmm I have never used Sencha Touch, I didn't know that. The ExtJS-way of defining a model is a little different:

Code:
Ext.define('MyApp.model.MyModel', {
    extend: 'Ext.data.Model',

    fields: [{
        name: 'id',
        type: 'int'
    }, {
        name: 'name',
        type: 'string'
    }, {
        name: 'ratio',
        type: 'float'
    }]
});
So, is the output of sencha generate model command a bug? Shouldn't it be the one compatible with ExtJS SDK?