Skip to content

Commit

Permalink
UPDATE
Browse files Browse the repository at this point in the history
  • Loading branch information
lksilva committed Aug 29, 2018
1 parent 7a354a8 commit 5eeb1ec
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions JS/JS-br.md
Original file line number Diff line number Diff line change
Expand Up @@ -502,9 +502,9 @@ Object.setPrototypeOf(d, MyData.prototype)
Object.setPrototypeOf(MyData.prototype, Date.prototype)
```
The implementation idea of the above inheritance: first create the instance of parent class => change the original `__proto__` of the instance, connect it to the `prototype` of child class => change the `__proto__` of child class’s `prototype` to the `prototype` of parent class.
A implementação da idéia acima sobre herança: primeiro cria uma instância da classe do pai => muda o original `__proto__` de instância, conectado ao `prototype` da classe do filho => muda o `__proto__` da classe do filho `prototype` para o `prototype` da classe do pai.
The inheritance implement with the above method can perfectly solve the restriction on low-level of JS.
A herança de implementação com o método acima pode perfeitamente resolve a restrição no baixo nível do JS.
# Deep and Shallow Copy
Expand Down

0 comments on commit 5eeb1ec

Please sign in to comment.