Created
December 16, 2014 01:21
-
-
Save pwfisher/073b5c42d8f84463ddbf to your computer and use it in GitHub Desktop.
"bubble" action for all Ember components which sends the given action
This file contains hidden or 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
Ember.Component.reopen({ | |
actions: { | |
bubble: function (action) { | |
console.log('[Component action.bubble]', arguments); | |
var temp = this.get(action); | |
this.set(action, action); | |
this.sendAction(action); | |
this.set(action, temp); | |
} | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment