Is there an after view change hook (much like didInsertElement)?

后端 未结 5 665
旧巷少年郎
旧巷少年郎 2021-02-06 08:07

Using the didInsertElement hook, I\'m able to do some jQuery plugin initialization that is needed. However, if a property changes, Ember re-renders the view, but do

5条回答
  •  悲&欢浪女
    2021-02-06 08:36

    You could also hook into the childViews array and observe changes on that.

    Something like this works but I don't think it's a good performance practice.

    childViewsArrayDidChange: function() {
      console.log("childViews-Array did change");
    }.observes('childViews.@each')
    

提交回复
热议问题