Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/121.0.0.0 Safari/537.36
Chrome 121
Windows
Desktop
9 months ago
Test name Executions per second
hasAttribute 3423362.0 Ops/sec
getAttribute 3334767.8 Ops/sec
classList 3126232.2 Ops/sec
hasAttribute single 3954023.2 Ops/sec
getAttribute single 3334868.0 Ops/sec
classList single 3059383.0 Ops/sec
HTML Preparation code:
Tests:
  • hasAttribute

  • getAttribute

  • classList

  • hasAttribute single

  • getAttribute single

  • classList single


;