function test(){
var arr = [].slice.call(arguments,0);
console.log("arr",arr);
}
test(1,2,3)
// 输出 数组[1,2,3]
[].slice.call(arguments,0) 就获得了参数数组对象
来源: https://www.2cto.com/kf/201710/687971.html