mercredi 31 octobre 2018

Ember does not update value of based on another property

Hi i have a simple code that updates a component's property value e.g. with a button click, and based on that value i need to update the value of the input text, like so:

template:
<button>update</button>

component.js:
myValue: Ember.computed("product", function(){ if(this.get("product")) { return this.get("product"); } }),

But although, the "product" property is updated , the input value stays the same, computed function is not triggered.

Am i missing anything?




Aucun commentaire:

Enregistrer un commentaire