Script Preparation code:
Tests:

Historical Performance Data aggregated from 25 community runs

Desktop Results:
Chrome 25 runs
substring and substring
9.4M/s
replace inline regex
7.4M/s

Fastest: substring and substring (1.3x faster)

View exact numbers
  • substring and substring: 9,410,618 ops/sec
  • replace inline regex: 7,361,394 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
    substring and substring
    replace inline regex

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 5 months ago)
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/145.0.0.0 Safari/537.36
Chrome 145 on Mac OS X 10.15.7
View result in a separate tab
substring and substring
17.9M/s
replace inline regex
14.1M/s
View exact numbers
Test name Executions per second
substring and substring 17,916,472 Ops/sec
replace inline regex 14,084,310 Ops/sec