Run details:
Mozilla/5.0 (Android 13; Mobile; rv:109.0) Gecko/111.0 Firefox/111.0
Firefox Mobile 111
Android
Mobile
one year ago
Test name Executions per second
regex start 335.2 Ops/sec
startsWith 736.0 Ops/sec
regex end 317.3 Ops/sec
endsWith 707.5 Ops/sec
indexOf start 8764.2 Ops/sec
indexOf end 8779.3 Ops/sec
charAt end 1428.1 Ops/sec
charCodeAt end 1425.5 Ops/sec
charCodeAt start 1303.7 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • regex start

  • startsWith

  • regex end

  • endsWith

  • indexOf start

  • indexOf end

  • charAt end

  • charCodeAt end

  • charCodeAt start