ember.js - Ember: how to fire observers when any Em.A inside an Em.Object change -


let's have like

property: em.object.create(foo: em.a([]), bar: em.a([])),  onanyarraychange: function(){ //some code }.observes('what here??') 

thing don't want explicitly

.observes('property.foo.[]', 'property.bar.[]') 

i'd love like

.observes('property.each_key.[]') 

is there way it?

yes possible @each property. see: http://emberjs.com/api/classes/ember.array.html#property__each

what need convert property ember.object ember.arrayproxy this:

property: em.arrayproxy.create({   content: [     em.a([]), // used foo     em.a([]) // used bar   ] }); 

and can:

.observes('property.@each.[]') 

Comments

Popular posts from this blog

python - mat is not a numerical tuple : openCV error -

c# - MSAA finds controls UI Automation doesn't -

wordpress - .htaccess: RewriteRule: bad flag delimiters -