在connectOutlet中使用的Ember路由和applicationController

时间:2012-07-09 07:31:03

标签: ember.js

我有这个实用的例子,是ember routing http://jsfiddle.net/C7LrM/102/

的小提琴

我想将ApplicationController更改为ApplicationzController lije this http://jsfiddle.net/C7LrM/102/

并致电

router.get('applicationzController').connectOutlet('profile');

但它不起作用,ApplicationController只是一个名称或更多的东西?我做错了什么。

我正在开发一个更大的应用程序的单个组件,所以我喜欢将我的componentController保持在我的堆栈顶部,并在内部使用路由/状态作为我的组件。

1 个答案:

答案 0 :(得分:4)

截至今天,根控制器应该是applicationController(硬编码为ember源......)。所以你不能自由命名它。