append vs appendChild

Benchmark created on


Preparation HTML

<div id="container"></div>

Test runner

Ready to run.

Testing in
TestOps/sec
append
const node = document.createElement("div");
document.querySelector("#container").append(node);
ready
appendChild
const node = document.createElement("div");
document.querySelector("#container").appendChild(node);
ready

Revisions

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