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
Benchmark.js
String.includes
19.0M/s
RegEx.test
7.9M/s
String.match
4.9M/s
View exact numbers
Test name Executions per second
String.includes 18,990,608 Ops/sec
RegEx.test 7,891,011 Ops/sec
String.match 4,891,133 Ops/sec
Script Preparation code:
Tests: