Which equals operator (== vs ===) is faster?
Is there a performance benefit to replacing == with ===?
6 years ago
User agent:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/11.1.2 Safari/605.1.15
Test name |
Executions per second |
test equality |
28991.2 Ops/sec |
test strict equality |
29134.1 Ops/sec |
Tests:
-
test equality
-
test strict equality
Open this result on MeasureThat.net