I am upgrading an application that customizes Ember.View for the top-level application.hbs. There I have an event handler that needs access to the event object that gets passed in:
ApplicationView = Ember.View.extend({
click(event) {
// Need event here.
}
});
Now that Ember.View is deprecated, I'm not sure how to replace this logic.
I could add an action handler at some div that would capture the event of interest in application.hbs:
<div {{action "topLevelClick"}}>
...
</div>
But although this fires, I don't have access to the event object.
Any thoughts on how to handle this?
Aucun commentaire:
Enregistrer un commentaire