single vs multiple innerhtml (v2)

Revision 2 of this benchmark created on


Preparation HTML

<div id="main"></div>

Test runner

Ready to run.

Testing in
TestOps/sec
single
e= document.getElementById("main");
e.innerHTML = "<div style='background:red;width:50px;'>Text</div><div style='background:red;width:50px;'>Text2</div><div style='background:red;width:50px;'>Text3</div>";
ready
multiple
e= document.getElementById("main");
e.innerHTML = "<div style='background:red;width:50px;'>Text</div>"
e.innerHTML = "<div style='background:red;width:50px;'>Text2</div>"
e.innerHTML = "<div style='background:red;width:50px;'>Text3</div>";
ready

Revisions

You can edit these tests or add more tests to this page by appending /edit to the URL.