HTML Preparation code:
Script Preparation code:
Tests:
  • impicit elementId

  • explicit getElementById

  • id function

  • id var function

  • id var arrow function

  • element var

  • var element in block scope

  • let element in block scope

  • const element in block scope

Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results
  • Test case name Result
    impicit elementId
    explicit getElementById
    id function
    id var function
    id var arrow function
    element var
    var element in block scope
    let element in block scope
    const element in block scope

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 5 years ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:66.0) Gecko/20100101 Firefox/66.0
Firefox 66 on Windows
View result in a separate tab
Test name Executions per second
impicit elementId 22301.4 Ops/sec
explicit getElementById 28488.1 Ops/sec
id function 23198.5 Ops/sec
id var function 24085.6 Ops/sec
id var arrow function 25727.0 Ops/sec
element var 32417.2 Ops/sec
var element in block scope 30909.1 Ops/sec
let element in block scope 29645.1 Ops/sec
const element in block scope 32166.2 Ops/sec