0
我在分析基本的todo应用程序。sproutcore属性(@each)未更新
为什么当我删除StatsView
(来自主todos.js和todos.handlebars)todoListController
的remaining
方法(属性)会停止自行更新?
Todos.todoListController = SC.ArrayController.create({
...
remaining: function() {
console.log('remaining');//doesn't apear in the console
return this.filterProperty('isDone', false).get('length');
}.property('@each.isDone').cacheable(),
...
});
我能想象,这是因为与StatsView
我删除了绑定。但是不应该这样,@each
会关注这些变化吗?