Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/100.0.4896.127 Safari/537.36
Chrome 100
Mac OS X 10.15.7
Desktop
2 years ago
Test name Executions per second
Array.prototype.concat 1339118.4 Ops/sec
spread operator 2060388.5 Ops/sec
Push Spread 2623224.0 Ops/sec
Push Apply 2583901.8 Ops/sec
Push Loop 2951658.2 Ops/sec
Array ForEach 5915322.0 Ops/sec
Script Preparation code:
Tests:
  • Array.prototype.concat

  • spread operator

  • Push Spread

  • Push Apply

  • Push Loop

  • Array ForEach