Run details:
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/120.0.0.0 Safari/537.36
Chrome 120
Linux
Desktop
2 years ago
String.includes
28.6M/s
RegEx.test
12.3M/s
String.match
7.3M/s
View exact numbers
Test name Executions per second
String.includes 28,615,040 Ops/sec
RegEx.test 12,258,466 Ops/sec
String.match 7,255,272 Ops/sec
Script Preparation code:
Tests: