首页 > 代码库 > Array.prototype.push.apply

Array.prototype.push.apply

Array.prototype.push.apply(a,b) || a.push.apply(a,b);
var a=[1,2,3],b=[4,5,6];
Array.prototype.push.apply(a,b) 
a===[1, 2, 3, 4, 5, 6]
b===[4, 5, 6]

http://blog.csdn.net/maoguiyou/article/details/51433551

Array.prototype.push.apply