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
11 months ago
Test name Executions per second
Remove firstChild 10484779.0 Ops/sec
Remove lastChild 10297816.0 Ops/sec
innerHTML 4467892.5 Ops/sec
innerText 6600635.5 Ops/sec
textContent 4245637.5 Ops/sec
firstChild.remove 10175640.0 Ops/sec
range 2258990.5 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • Remove firstChild

  • Remove lastChild

  • innerHTML

  • innerText

  • textContent

  • firstChild.remove

  • range