Script Preparation code:
Tests:

Historical Performance Data aggregated from 5 community runs

Desktop Results:
Chrome 5 runs
Array.includes
36.2M/s
RegEx.test
18.8M/s

Fastest: Array.includes (1.9x faster)

View exact numbers
  • Array.includes: 36,209,028 ops/sec
  • RegEx.test: 18,800,204 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
    RegEx.test
    Array.includes

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 7 months ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/143.0.0.0 Safari/537.36
Chrome 143 on Windows
View result in a separate tab
Array.includes
159.1M/s
RegEx.test
78.4M/s
View exact numbers
Test name Executions per second
Array.includes 159,115,136 Ops/sec
RegEx.test 78,391,856 Ops/sec