26

漫谈JS中的prototype-尽其在我,简单是美

 5 years ago
source link: http://blog.51cto.com/solarboy/2155739
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
prototype是JS中常令人迷惑的一个概念,之所以令人迷惑是因为大家总是想把它与面向对象的经典框架结合起来,反而束缚了自己的思维。JS是一个纯粹的面向对象系统,使用构造函数的prototype实现了对象属性间的共享,本文探索了prototype的本质并归纳总结了prototype的使用规则。

Recommend

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK