Test name | Executions per second |
---|---|
Array.prototype.concat | 6578037.5 Ops/sec |
spread operator | 5315089.5 Ops/sec |
jQuery merge | 1996757.9 Ops/sec |
var params = [ "hello", true, 7 ];
var other = [ 1, 2 ].concat(params);
var params = [ "hello", true, 7 ]
var other = [ 1, 2, params ]
var params = [ "hello", true, 7 ];
var other = $.merge([1, 2], params);