Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/96.0.4664.110 Safari/537.36
Chrome 96
Mac OS X 10.13.6
Desktop
2 years ago
Test name Executions per second
getElementById 5637347.5 Ops/sec
getElementsByTagName 2643858.2 Ops/sec
querySelector 3479706.5 Ops/sec
getElementsByClassName 3169549.0 Ops/sec
getElementsByName 3640121.2 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • getElementById

  • getElementsByTagName

  • querySelector

  • getElementsByClassName

  • getElementsByName


;