Created
November 20, 2015 07:47
-
-
Save jervert/96b73589026daed56e5e to your computer and use it in GitHub Desktop.
Remove view from Backbone without remove view element
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
removeView = function(view) { | |
view.undelegateEvents(); | |
view.$el.empty().off(); | |
view.unbind(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment