Guest User

Untitled

a guest
Aug 15th, 2018
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1. import Ember from 'ember';
  2.  
  3. export default Ember.Component.extend({
  4. // name: 'test',
  5.  
  6. init() {
  7. this._super(...arguments);
  8. //this.name = 'new test';
  9. console.log('I am in init');
  10. },
  11.  
  12. didUpdateAttrs() {
  13. this._super(...arguments);
  14. //this.name='test';
  15. console.log('I am in didUpdateAttrs');
  16.  
  17. },
  18.  
  19. didReceiveAttrs() {
  20. this._super(...arguments);
  21. console.log('I am in didReceiveAttrs');
  22. },
  23.  
  24. actions: {
  25. changeName: function() {
  26. this.set('name', 'new test');
  27. }
  28. }
  29.  
  30. });
Add Comment
Please, Sign In to add comment