Run details:
Mozilla/5.0 (Linux; Android 8.0.0; RNE-L22) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.83 Mobile Safari/537.36
Chrome Mobile 83
Android 8.0.0
Mobile
4 years ago
Test name Executions per second
getElementById 599574.4 Ops/sec
querySelector 383550.1 Ops/sec
getElementsByClassName 449126.9 Ops/sec
querySelectorAll 211638.5 Ops/sec
querySelector class 441918.2 Ops/sec
HTML Preparation code:
Tests:
  • getElementById

  • querySelector

  • getElementsByClassName

  • querySelectorAll

  • querySelector class


;