Last active
August 29, 2015 14:24
-
-
Save elwayman02/1fa268f4e4aa4bfc2945 to your computer and use it in GitHub Desktop.
New Twiddle
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
export default Ember.Component.extend({ | |
classNames: ['tharp-component'], | |
firstName: 'Daniel', | |
lastName: 'Tharp' | |
}); |
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
import Ember from 'ember'; | |
export default Ember.Controller.extend({ | |
appName:'Ember Twiddle', | |
amIVisible: true, | |
buttonText: Ember.computed('amIVisible', function () { | |
return this.get('amIVisible') ? 'Hide' : 'Show'; | |
}), | |
actions: { | |
toggle() { | |
this.toggleProperty('amIVisible'); | |
} | |
} | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment