Run details:
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Ubuntu Chromium/70.0.3538.77 Chrome/70.0.3538.77 Safari/537.36
Chromium 70
Ubuntu
Desktop
5 years ago
Test name Executions per second
Object.assign 2714370.2 Ops/sec
Object spread 1696322.6 Ops/sec
Object Indexed Add 269234368.0 Ops/sec
Object Dot Add 522939168.0 Ops/sec
Array.prototype.concat 3283148.5 Ops/sec
Array.prototype.push (grouped) 11523660.0 Ops/sec
Array.prototype.push (single) 12893846.0 Ops/sec
Array Spread 5487085.0 Ops/sec
Tests:
  • Object.assign

  • Object spread

  • Object Indexed Add

  • Object Dot Add

  • Array.prototype.concat

  • Array.prototype.push (grouped)

  • Array.prototype.push (single)

  • Array Spread


;