HTML Preparation code:
Script Preparation code:
Tests:
  • Select Element by ID - Javascript

  • Change CSS - jQuery

  • Change CSS - Javascript

  • Select Element by ID - jQuery

  • Change inner text - Javascript

  • Change inner text - jQuery

  • Get element by tag name - Javascript

  • Get element by tag name - jQuery

  • Get element by name - Javascript

  • Get element by name - jQuery

  • Get element by existing attribute - Javascript

  • Get element by existing attribute - jQuery

  • Get element by class name - Javascript

  • Get element by class name - jQuery

  • Select sub-element - Javascript

  • Select sub-element - jQuery

  • Loop through elements - Javascript

  • Loop through elements - jQuery

  • Add and remove Element - Javascript

  • Add and remove Element - jQuery

  • Add and Remove Class - Javascript

  • Add and Remove Class - jQuery

Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results
  • Test case name Result
    Select Element by ID - Javascript
    Change CSS - jQuery
    Change CSS - Javascript
    Select Element by ID - jQuery
    Change inner text - Javascript
    Change inner text - jQuery
    Get element by tag name - Javascript
    Get element by tag name - jQuery
    Get element by name - Javascript
    Get element by name - jQuery
    Get element by existing attribute - Javascript
    Get element by existing attribute - jQuery
    Get element by class name - Javascript
    Get element by class name - jQuery
    Select sub-element - Javascript
    Select sub-element - jQuery
    Loop through elements - Javascript
    Loop through elements - jQuery
    Add and remove Element - Javascript
    Add and remove Element - jQuery
    Add and Remove Class - Javascript
    Add and Remove Class - jQuery

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 10 months ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:121.0) Gecko/20100101 Firefox/121.0
Firefox 121 on Windows
View result in a separate tab
Test name Executions per second
Select Element by ID - Javascript 8980433.0 Ops/sec
Add and remove Element - jQuery 216773.0 Ops/sec
Add and remove Element - Javascript 1839136.0 Ops/sec
Loop through elements - jQuery 154941.1 Ops/sec
Loop through elements - Javascript 524786.9 Ops/sec
Select sub-element - jQuery 3439698.0 Ops/sec
Select sub-element - Javascript 1498517.9 Ops/sec
Get element by class name - jQuery 2264442.2 Ops/sec
Get element by class name - Javascript 9321017.0 Ops/sec
Get element by existing attribute - jQuery 117826.3 Ops/sec
Get element by existing attribute - Javascript 126611.3 Ops/sec
Get element by name - jQuery 116502.9 Ops/sec
Get element by name - Javascript 127658.2 Ops/sec
Get element by tag name - jQuery 2409280.8 Ops/sec
Get element by tag name - Javascript 9489680.0 Ops/sec
Change inner text - jQuery 1678677.4 Ops/sec
Change inner text - Javascript 7439284.5 Ops/sec
Select Element by ID - jQuery 9416997.0 Ops/sec
Change CSS - Javascript 1621382.2 Ops/sec
Change CSS - jQuery 769184.0 Ops/sec
Add and Remove Class - Javascript 1416983.0 Ops/sec
Add and Remove Class - jQuery 538526.9 Ops/sec