I am trying to make an ember application. I have a computed property and the controller looks like this:
// The Controller
Todos.Controller = Ember.Controller.create({
// ** SNIP ** //
countCompleted: function()
{
return this.get('todos').filterProperty('completed', true).length
}.property(),
});
// The View
{{Todos.Controller.countCompleted.property}} Items Left
Now the tutorial I'm following is using an older version of Ember.JS. I've fixed every error but this:
Uncaught Error: assertion failed: Ember.Object.create no longer supports defining computed properties.
What's the alternative way to do this?