Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.138 Safari/537.36 OPR/68.0.3618.206
Opera 68
Windows
Desktop
3 years ago
Test name Executions per second
regex start 337.5 Ops/sec
startsWith 418.4 Ops/sec
regex end 318.7 Ops/sec
endsWith 404.1 Ops/sec
indexOf start 4724.2 Ops/sec
indexOf end 5079.1 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • regex start

  • startsWith

  • regex end

  • endsWith

  • indexOf start

  • indexOf end