Test case name | Result |
---|---|
text.includes() | |
regex.test() | |
string.match() | |
string.indexOf() |
Test name | Executions per second |
---|---|
text.includes() | 14511900.0 Ops/sec |
regex.test() | 8799024.0 Ops/sec |
string.match() | 7015687.0 Ops/sec |
string.indexOf() | 15178760.0 Ops/sec |