Run details:
Mozilla/5.0 (Android 11; Mobile; rv:103.0) Gecko/103.0 Firefox/103.0
Firefox Mobile 103
Android
Mobile
2 years ago
Test name Executions per second
text.includes() 13964733.0 Ops/sec
regex.test() 8921276.0 Ops/sec
string.match() 5958416.5 Ops/sec
string.indexOf() 15063686.0 Ops/sec
Script Preparation code:
Tests:
  • text.includes()

  • regex.test()

  • string.match()

  • string.indexOf()