Tests:
  • .push()

    AخA
     
    const arr = [1,2];
    arr.push(3);
  • spread operator

     
    let arr = [1,2];
    arr = [...arr, 3]; 
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results

Experimental features:

  • Test case name Result
    .push()
    spread operator

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 2 years ago)
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.5112.81 Safari/537.36 Edg/104.0.1293.47
Chrome 104 on Mac OS X 10.15.7
View result in a separate tab
Test name Executions per second
.push() 91445056.0 Ops/sec
spread operator 55066828.0 Ops/sec