Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/81.0.4044.129 Safari/537.36 OPR/68.0.3618.91
Opera 68
Mac OS X 10.11.6
Desktop
3 years ago
Test name Executions per second
querySelector 1736453.0 Ops/sec
querySelectorAll 623637.9 Ops/sec
getElementsByClassName 2274175.5 Ops/sec
querySelector (ID) 1281827.4 Ops/sec
getElementsByID 1826156.8 Ops/sec
HTML Preparation code:
Tests:
  • querySelector

  • querySelectorAll

  • getElementsByClassName

  • querySelector (ID)

  • getElementsByID


;