Test name | Executions per second |
---|---|
createTextNode | 367922.9 Ops/sec |
textContent | 1502357.5 Ops/sec |
innerText | 585766.9 Ops/sec |
innerHTML | 132536.7 Ops/sec |
var a = document.createElement('a');
a.appendChild(document.createTextNode('text'));
a.textContent = 'text';
a.innerText = 'text';
a.innerHTML = 'text';