Rally Class 分配的 xtype 值在哪里

Where are Rally Class xtype Values Assigned

我的目标:在现有拉力赛 class 的基础上建造一个 class。
我的 Objective:为我的新 class 创建一个 xtype。

我已经检查了 Rally Grid 和 Rally Tree Grid 的公开来源。我看到他们引用了他们用于自己实现的其他 classes 的 xtype,但我没有看到任何地方声明了他们自己的 xtype。

这些 xtype 映射是在哪里创建/维护的?

这是一个相当令人困惑的 ExtJS 组件系统实现细节。

xtypes 在组件 class 上声明如下:

alias: 'widget.mythingy'

您可以在此处查看 post 中提到的 TreeGrid 示例: https://help.rallydev.com/apps/2.1/doc/source/TreeGrid.html#Rally-ui-grid-TreeGrid

一旦您使用以 widget. 开头的别名定义组件 class,您就可以在添加到容器时引用它。

this.add({ xtype: 'mythingy' });