Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
append vs innerHTML d
(version: 0)
Comparing performance of:
innerHTML vs append
Created:
4 years ago
by:
Guest
Jump to the latest result
HTML Preparation code:
<p id='bar'></p>
Script Preparation code:
var el = document.getElementById('bar'); var html = '<span class="red">Some text here</span> fdsfjdasfkjdasfkljdasflj';
Tests:
innerHTML
el.innerHTML += html; el.innerHTML = '';
append
el.append(html); el.innerHTML = '';
Rendered benchmark preparation results:
Suite status:
<idle, ready to run>
Run tests (2)
Previous results
Fork
Test case name
Result
innerHTML
append
Fastest:
N/A
Slowest:
N/A
Latest run results:
No previous run results
This benchmark does not have any results yet. Be the first one
to run it!
Related benchmarks:
jQuery vs pure JS : html
append vs innerHTML
JS: append vs appendChild
append vs innerHTML loop
Comments
Confirm delete:
Do you really want to delete benchmark?