Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/17.0 Safari/605.1.15
Safari 17
Mac OS X 10.15.7
Desktop
one year ago
Test name Executions per second
querySelector 3357704.8 Ops/sec
querySelectorAll 2267791.2 Ops/sec
getElementsByClassName 5777358.0 Ops/sec
querySelector (ID) 3338696.8 Ops/sec
getElementsByID 5782549.5 Ops/sec
HTML Preparation code:
Tests:
  • querySelector

  • querySelectorAll

  • getElementsByClassName

  • querySelector (ID)

  • getElementsByID


;