我们知道,给JavaScript类添加原形(prototype)方法是很简单的。而且常用的有下面这两种方法,可是这两种方法在使用时有区别吗? JScript Class: function JSClass() { } Extends prototype method: JSClass.prototype.MethodA = function() { }; Or function = JSClass.prototype.MethodA() { }; 转载于:https://www.cnblogs.com/birdshome/archive/2005/03/01/108461.html