Prototype vs __proto__ Javascript interview question

Publicado em: 05 Outubro 2023
no canal de: code savera
705
12

Prototype is only accessible on constructors, while dunder proto is only accessible on instances.

"The function 'Person' on the screen is a constructor function that has a 'fullName' method defined on its prototype."

"When creating an instance, 'person1,' the prototype of the 'Person' constructor becomes linked to the dunder proto of the 'person1' instance."
//run the code

"And because of this linkage, we can now access the 'fullName' method of the constructor's prototype from the 'person1' instance."


Nesta página do site você pode assistir ao vídeo on-line Prototype vs __proto__ Javascript interview question duração hora minuto segundo em boa qualidade , que foi baixado pelo usuário code savera 05 Outubro 2023, compartilhe o link com seus amigos e conhecidos, no youtube este vídeo já foi visto 705 vezes e gostou 12 espectadores. Boa visualização!