Skip to content

Instantly share code, notes, and snippets.

@KTKate
Last active August 29, 2015 14:24
Show Gist options
  • Save KTKate/c6b3a64fe9f95463be2a to your computer and use it in GitHub Desktop.
Save KTKate/c6b3a64fe9f95463be2a to your computer and use it in GitHub Desktop.
How to bubble this action
{{#detail-area as |goalArea|}}
{{#if showForm}}
//form stuff
<button {{action "save" details target=goalArea}}>Submit</button>
{{else}}
//other stuff
{{/if}}
{{/detail-area}}
//GoalAreaComponent js
showForm = false,
actions:{
save: function(details){
this.sendAction('save' details);
//some logic to return whether it saved
this.toggleProperty('showForm');
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment