Tests:
  • slice with spread operator

    AخA
     
    var params = [ "hello", true, 7, "test" ];
    var other = [...params.slice(0, 1), ...params.slice(2)];
  • slice with splice operator

     
    var params = [ "hello", true, 7, "test" ];
    var other = params.slice().splice(1, 1);
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results

Experimental features:

  • Test case name Result
    slice with spread operator
    slice with splice operator

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 5 years ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.132 Safari/537.36
Chrome 80 on Windows
View result in a separate tab
Test name Executions per second
slice with spread operator 7629570.0 Ops/sec
slice with splice operator 11286604.0 Ops/sec