Skip to content

Instantly share code, notes, and snippets.

@svparijs
Created December 17, 2012 13:17
Show Gist options
  • Save svparijs/4318210 to your computer and use it in GitHub Desktop.
Save svparijs/4318210 to your computer and use it in GitHub Desktop.
Current Model
App.Person = DS.Model.extend({
firstname: DS.attr('string'),
lastname: DS.attr('string'),
fullName: function() {
return this.get('firstname') + ' ' + this.get('lastname');
}.property('firstname', 'lastname'),
didLoad: function() {
console.log(this.get('fullName') +" finished loading.");
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment