Take the 2-minute tour ×

Given the following code, do i need to remove the observer at any point? I feel like i do..

App.Views.MyView = Ember.View.extend({
    init: function ()
        var self = this;

        // Add observer
        self.addObserver('App.Path.To.ItemsObject', self, self._itemsObserver);

        return this._super();
    _itemsObserver: function(){
        //Do something
share|improve this question
add comment

1 Answer

up vote 1 down vote accepted

Yes you have to. You can use the events of willInsertElement and willDestroyElement for this task. See Doc of Ember.View

share|improve this answer
add comment

Your Answer


