QuerySelectorAll vs getElementByXpathFastest: QuerySelectorAll (5.5x faster)
949,114 ops/sec
173,914 ops/sec
Results show median performance across all community submissions. Run this benchmark yourself to verify on your device.
| Test case name | Result |
|---|---|
| QuerySelectorAll | |
| getElementByXpath |
| Test name | Executions per second |
|---|---|
| ✓ QuerySelectorAll | 1,364,809 Ops/sec |
| getElementByXpath | 169,483 Ops/sec |