Programming, Top Programming Languages.
{ name: '', age: 0, toString() { return `${this.name} (${this.age} y/o)` } } var bob = Object.assign(Object.create(person), { name: 'Bob', age: 22, }) This is a prototypal inheritance pattern popularized by Douglas Crockford a long time ago. If you’re unfamiliar with this concept, you may not be