javascript prototype 的简单用法

1 /* 2 function Box() { 3 this.a = []; 4 this.fn = function() {} 5 } 6 7 var box1 = new Box(); 8 var box2 = new Box(); 9 box1.a.push(1); 10 box1.a.pus
posted @ 2016-02-16 10:55  bronana  阅读(182)  评论(0编辑  收藏  举报