Created
April 29, 2016 18:22
-
-
Save easierbycode/4e94f18f120177292a5ce64829e58ddf 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
let project = { | |
getTaskCount() { | |
return 50; | |
} | |
} | |
let softwareProject = { | |
getTaskCount() { | |
return super.getTaskCount() + 25; | |
} | |
} | |
Object.setPrototypeOf(softwareProject, project); | |
softwareProject.getTaskCount() | |
// 75 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment