Results 1 to 2 of 2

Thread: "alias" the same as "xtype"?

  1. #1
    Touch Premium Member
    Join Date
    Jun 2011
    Posts
    474

    Default "alias" the same as "xtype"?

    Is "alias" the same as "xtype"?

    eg:

    Code:
    Ext.define('Yi.view.product.List', {
      extend: 'Ext.grid.Panel',
      alias: 'widget.productlist',
    });
    Now it has the xtype of widget.productlist right?

    If so, isn't it better that you rename it to "xtype" instead of "alias" instead?

  2. #2
    Sencha - Community Support Team jsakalos's Avatar
    Join Date
    Apr 2007
    Location
    Slovakia
    Posts
    27,664
    Answers
    512

    Default

    Alias has been introduced in Ext 4 and it is namespaced so alias:'widget.productlist' translates to xtype:'product list'. In other words, in Ext.define you set alias and in Ext.create you use type:'productlist'.
    Jozef Sakalos, aka Saki

    Education, extensions and services for developers at new http://extjs.eu
    News: Grid MultiSearch Plugin, Grid MultiSort Plugin, Configuring ViewModel Hierarchy


Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •