Script Preparation code:
Tests:

Historical Performance Data aggregated from 30 community runs

Desktop Results:
Chrome 25 runs
remove finding element using indexof
1.1M/s
remove finding element using filter
25K/s

Fastest: remove finding element using indexof (42.2x faster)

View exact numbers
  • remove finding element using indexof: 1,060,255 ops/sec
  • remove finding element using filter: 25,138 ops/sec
Firefox 5 runs
remove finding element using indexof
208K/s
remove finding element using filter
23K/s

Fastest: remove finding element using indexof (9.1x faster)

View exact numbers
  • remove finding element using indexof: 207,733 ops/sec
  • remove finding element using filter: 22,810 ops/sec

Results show median performance across all community submissions. Run this benchmark yourself to verify on your device.

Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results
  • Test case name Result
    remove finding element using indexof
    remove finding element using filter

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 9 months ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/141.0.0.0 Safari/537.36 Edg/141.0.0.0
Chrome 141 on Windows
View result in a separate tab
remove finding element using indexof
1.2M/s
remove finding element using filter
25K/s
View exact numbers
Test name Executions per second
remove finding element using indexof 1,205,084 Ops/sec
remove finding element using filter 24,715 Ops/sec