Home > front end >  Why Foo (). The prototype. The constructor is equal to the function?
Why Foo (). The prototype. The constructor is equal to the function?

Time:04-06

 function Foo () {}; 
Foo. The prototype. The constructor===Foo//true


This concept is a little confused, why the function prototype of the object's constructor, equal to the function itself? My shallow understanding of, the prototype of the function prototype, is founded by yourself,,, but feel so understand it seems unlikely to again,,,

That just memorizing remember? It is very easy to remember, but still want to know why, don't know if you have any ideas?
  • Related