This repository has been archived on 2023-03-18. You can view files and clone it, but cannot push or open issues or pull requests.
osr-discourse-src/app/assets/javascripts/discourse/mixins/cleans-up.js.es6
2018-06-15 17:03:24 +02:00

12 lines
380 B
JavaScript

// Include this mixin if you want to be notified when the dom should be
// cleaned (usually on route change.)
export default Ember.Mixin.create({
_initializeChooser: function() {
this.appEvents.on("dom:clean", this, "cleanUp");
}.on("didInsertElement"),
_clearChooser: function() {
this.appEvents.off("dom:clean", this, "cleanUp");
}.on("willDestroyElement")
});