Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:121.0) Gecko/20100101 Firefox/121.0
Firefox 121
Mac OS X 10.15
Desktop
10 months ago
Test name Executions per second
text.includes() 52836748.0 Ops/sec
regex.test() 42784776.0 Ops/sec
string.match() 24523410.0 Ops/sec
string.indexOf() 740628160.0 Ops/sec
Script Preparation code:
Tests:
  • text.includes()

  • regex.test()

  • string.match()

  • string.indexOf()


;