Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36
Chrome 126
Windows
Desktop
6 months ago
Test name Executions per second
hasAttribute 526786.4 Ops/sec
getAttribute 514362.8 Ops/sec
classList 552396.6 Ops/sec
hasAttribute single 687726.9 Ops/sec
getAttribute single 582988.5 Ops/sec
classList single 615408.9 Ops/sec
HTML Preparation code:
Tests:
  • hasAttribute

  • getAttribute

  • classList

  • hasAttribute single

  • getAttribute single

  • classList single