EXTJS4.0遇到的问题解决心得
在写EXTJS时经常遇到的错误有很多,现在一点点记录下来,为解决相关问题提供帮助!
1、substring问题
Uncaught TypeError: Cannot read property 'substring' of undefined
at Object.parseNamespace (ext-all-debug.js:5057)
at Object.get (ext-all-debug.js:5165)
at Object.instantiate (ext-all-debug.js:5448)
at Object.instantiateByAlias (ext-all-debug.js:5430)
at Object.widget (ext-all-debug.js:5715)
at constructor.create (ext-all-debug.js:21937)
at constructor.lookupComponent (ext-all-debug.js:38070)
at constructor.prepareItems (ext-all-debug.js:38040)
at constructor.add (ext-all-debug.js:38097)
at constructor.initItems (ext-all-debug.js:37872)
出现此类问题往往是xtype不对导致,要检查xtype中的内容是否有定义或者预加载。
2、不报错,长时间加载不出页面
此类问题为define定义时路径错误,应将viewx改为view
错误部分:Ext.define('App.viewx.DetailWin', {})

浙公网安备 33010602011771号