Run details:
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/94.0.4606.85 YaBrowser/21.11.3.953 Yowser/2.5 Safari/537.36
Yandex Browser 21
Linux
Desktop
2 years ago
Test name Executions per second
querySelector 2068130.2 Ops/sec
querySelectorAll 586264.6 Ops/sec
getElementsByClassName 2549619.5 Ops/sec
querySelector (ID) 1214405.0 Ops/sec
getElementsByID 1671112.9 Ops/sec
HTML Preparation code:
Tests:
  • querySelector

  • querySelectorAll

  • getElementsByClassName

  • querySelector (ID)

  • getElementsByID


;