Skip to content

Instantly share code, notes, and snippets.

@Peege151
Created March 3, 2015 20:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Peege151/2fee7cbcad635daa5374 to your computer and use it in GitHub Desktop.
Save Peege151/2fee7cbcad635daa5374 to your computer and use it in GitHub Desktop.
Object.defineProperties
var Mammal = function(name) {
Object.defineProperties(this, {
"name": {
value: name
},
"offspring": {
value: []
}
});
}
// this doesn't pass the tests...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment