Skip to content

Commit 0e0f4e3

Browse files
authored
Update article.md
1 parent 9a6a9fb commit 0e0f4e3

File tree

1 file changed

+3
-1
lines changed
  • 1-js/08-prototypes/01-prototype-inheritance

1 file changed

+3
-1
lines changed

1-js/08-prototypes/01-prototype-inheritance/article.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ In JavaScript, objects have a special hidden property `[[Prototype]]` (as named
1212

1313
![prototype](object-prototype-empty.svg)
1414

15-
The prototype is a little bit "magical". When we want to read a property from `object`, and it's missing, JavaScript automatically takes it from the prototype. In programming, such thing is called "prototypal inheritance". Many cool language features and programming techniques are based on it.
15+
When we read a property from `object`, and it's missing, JavaScript automatically takes it from the prototype. In programming, such thing is called "prototypal inheritance". And soon we'll see the examples.
1616

1717
The property `[[Prototype]]` is internal and hidden, but there are many ways to set it.
1818

@@ -31,6 +31,8 @@ rabbit.__proto__ = animal;
3131
*/!*
3232
```
3333

34+
Here, the `rabbit` object has `animal` as its prototype.
35+
3436
```smart header="`__proto__` is a historical getter/setter for `[[Prototype]]`"
3537
Please note that `__proto__` is *not the same* as `[[Prototype]]`. It's a getter/setter for it.
3638

0 commit comments

Comments
 (0)