Run details:
Mozilla/5.0 (X11; Linux x86_64; rv:134.0) Gecko/20100101 Firefox/134.0
Firefox 134
Linux
Desktop
2 months ago
Test name Executions per second
text.includes() 1071030592.0 Ops/sec
regex.test() 22090136.0 Ops/sec
string.match() 14904651.0 Ops/sec
string.indexOf() 1751393280.0 Ops/sec
Script Preparation code:
Tests:
  • text.includes()

  • regex.test()

  • string.match()

  • string.indexOf()