I'm maintaining an application in Ember, and this "computed property" never actually gets computed by the if
block helper in the template.
Model:
var item = App.Item.create({
isAddedToCart: function () {
console.log('addedToCart method has been called');
return false;
}.property()
});
Template:
In my component that is in the template, the console.log()
never gets called, but the function seems to be tested if it's truth-y or not. Is there something wrong in my approach?
Aucun commentaire:
Enregistrer un commentaire