Difference Between __proto__ and prototype in Javascript

We will learn what is the difference between proto and prototype in Javascript

__proto__ is the actual object that is used in the lookup chain to resolve methods, etc.

prototype is the object that is used to build __proto__ when you create an object with new:


( new Foo ).__proto__ === Foo.prototype;
( new Foo ).prototype === undefined;

#javascript

Difference Between __proto__ and prototype in Javascript
8.75 GEEK