HTML Preparation code:
Tests:
  • Class

  • ID

  • data attribute

  • getElementById

  • getElementsByClassName

Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results
  • Test case name Result
    Class
    ID
    data attribute
    getElementById
    getElementsByClassName

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: one year ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:120.0) Gecko/20100101 Firefox/120.0
Firefox 120 on Windows
View result in a separate tab
Test name Executions per second
Class 3306890.5 Ops/sec
ID 3291698.8 Ops/sec
data attribute 3107549.0 Ops/sec
getElementById 5293324.0 Ops/sec
getElementsByClassName 3393544.0 Ops/sec


;