繁体   English   中英

Web应用程序Sencha Touch错误

[英]Web app sencha touch error

我在Sencha Touch的JavaScript代码的这一部分中有一些问题,我不知道如何解决。

new Ext.application({
  name: 'TouchStart',
  launch: function() {    
    this.viewport = new Ext.Panel({
      fullscreen: true,
      bodyPadding: 5,
      dockedItems: [            {
        dock : 'top',
        xtype: 'toolbar',
        title: 'Touch Start'
      }, {
        dock : 'top',
        xtype: 'toolbar',
        items: [{
            text: 'Hello Button'
        }]
      }],    
      html: 'Hello Panel'
    });
  }
});

控制台显示:

This.viewport = new Ext.Panel({
> Uncaught TypeError: undefined is not a function

萨拉姆,您必须将代码Ext.Panel更改为Ext.create('Ext.Panel',...........

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM