Update javascript-classical-vs-prototypal-inheritance.md
This commit is contained in:
@ -57,5 +57,8 @@ const dog = Object.create(animal);
|
|||||||
const cat = Object.create(animal);
|
const cat = Object.create(animal);
|
||||||
|
|
||||||
const max = Object.create(dog);
|
const max = Object.create(dog);
|
||||||
|
max.name = 'Max';
|
||||||
|
|
||||||
const claire = Object.create(cat);
|
const claire = Object.create(cat);
|
||||||
|
claire.name = 'Claire';
|
||||||
```
|
```
|
||||||
|
|||||||
Reference in New Issue
Block a user