Last active
June 19, 2017 01:55
-
-
Save kumkanillam/c75a27e5ff373add2c55233c0f8733e5 to your computer and use it in GitHub Desktop.
This file contains hidden or 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({ | |
name:'mycomp', | |
init(){ | |
this._super(...arguments); | |
console.log(' init mycomponent'); | |
}, | |
didReceiveAttrs(){ | |
console.log('didReceiveAttrs mycomponent'); | |
}, | |
didUpdateAttrs(){ | |
console.log('didUpdateAttrs mycomponent'); | |
}, | |
willUpdate(){ | |
console.log('willUpdate mycomponent'); | |
}, | |
didInsertElement(){ | |
console.log('didInsertElement mycomponent'); | |
}, | |
didUpdate(){ | |
console.log('didUpdate mycomponent'); | |
}, | |
willRender(){ | |
console.log('willRender mycomponent'); | |
}, | |
didRender(){ | |
console.log('didrender mycomponent'); | |
}, | |
actions:{ | |
toChange(){ | |
this.set('name','ChangedInMyComp '+new Date().toISOString()); | |
} | |
} | |
}); |
This file contains hidden or 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({ | |
name:'mycomp2', | |
cities: ['Barcelona', 'London', 'New York', 'Porto'], | |
destination: 'London', | |
init(){ | |
this._super(...arguments); | |
console.log(' init mycomponent2'); | |
}, | |
didReceiveAttrs(){ | |
console.log('didReceiveAttrs mycomponent2'); | |
}, | |
didUpdateAttrs(){ | |
console.log('didUpdateAttrs mycomponent2'); | |
}, | |
willUpdate(){ | |
console.log('willUpdate mycomponent2'); | |
}, | |
willRender(){ | |
console.log('willRender mycomponent2'); | |
}, | |
didUpdate(){ | |
console.log('didUpdate mycomponent2'); | |
}, | |
didInsertElement(){ | |
console.log('didInsertElement mycomponent2'); | |
}, | |
didRender(){ | |
console.log('didrender mycomponent2'); | |
}, | |
actions:{ | |
toChange(){ | |
this.set('name','ChangedInMyComp '+new Date().toISOString()); | |
}, | |
chooseDestination(city) { | |
this.set('destination', city); | |
} | |
} | |
}); |
This file contains hidden or 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({ | |
}); |
This file contains hidden or 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.12.1", | |
"EmberENV": { | |
"FEATURES": {} | |
}, | |
"options": { | |
"use_pods": false, | |
"enable-testing": false | |
}, | |
"dependencies": { | |
"jquery": "https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.3/jquery.js", | |
"ember": "2.12.0", | |
"ember-template-compiler": "2.12.0", | |
"ember-testing": "2.12.0" | |
}, | |
"addons": { | |
"ember-data": "2.12.1", | |
"ember-power-select": "1.8.1" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment