Last active
October 6, 2016 22:36
-
-
Save scottmessinger/ed778b37d75d558108599af80a80f5a3 to your computer and use it in GitHub Desktop.
Rerender entire tree
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({ | |
didReceiveAttrs(){ | |
this._super(...arguments) | |
console.log('didReceiveAttrs', 'a-child') | |
} | |
}); |
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({ | |
aPropertyInsideTheParent: "a", | |
didReceiveAttrs(){ | |
this._super(...arguments) | |
console.log('didReceiveAttrs', 'the-parent') | |
} | |
}); |
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({ | |
data: {val: 1}, | |
actions: { | |
increment(){ | |
Ember.set(this, "data", { | |
val: Ember.get(this, "data.val") + 1 | |
}) | |
} | |
} | |
}); |
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.10.5", | |
"EmberENV": { | |
"FEATURES": {} | |
}, | |
"options": { | |
"use_pods": false, | |
"enable-testing": false | |
}, | |
"dependencies": { | |
"jquery": "https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.3/jquery.js", | |
"ember": "beta", | |
"ember-data": "2.8.0", | |
"ember-template-compiler": "beta", | |
"ember-testing": "beta" | |
}, | |
"addons": {} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment