Created
December 17, 2015 22:06
-
-
Save Herriau/fbcd391e75a14930912b 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
import Ember from 'ember'; | |
export default Ember.Component.extend({ | |
foo: false, | |
bar: false, | |
classNameBindings: [':foo-bar', 'foo'], | |
onRerendered: function() { | |
$('body').append('did render!<br/>'); | |
}.on('didRender'), | |
actions: { | |
toggleFoo: function() { | |
this.toggleProperty('foo'); | |
}, | |
toggleBar: function() { | |
this.toggleProperty('bar'); | |
} | |
} | |
}); |
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
.foo-bar { | |
padding: 10px; | |
border: 3px solid black; | |
background-color: purple; | |
} | |
.foo-bar.foo { | |
background-color: cyan; | |
} |
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
{ | |
"version": "0.4.17", | |
"EmberENV": { | |
"FEATURES": {} | |
}, | |
"dependencies": { | |
"jquery": "https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.3/jquery.js", | |
"ember": "1.13.11", | |
"ember-data": "1.13.15", | |
"ember-template-compiler": "1.13.11" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment