原生链+对象冒充组合继承模式
    
            
摘要:function People(name,age){ this.name = name; this.age = age; this.run = function(){ alert(this.name+'在运动'); } } People.prototype.sex = '男'; People.pro
        
阅读全文
 
            
        
        
            
    对象冒充继承和原生链实现继承的方法和问题
    
            
摘要:function People(){ this.name='zhangsan'; this.age = 20; this.run = fcuntion(){ alert(this.name+'在运动'); } } //原生链 People.prototype.sex = '男'; People.pr
        
阅读全文