Window[] vs document.byId

Benchmark created by Ali on


Preparation HTML

<div id="Hello"></div>

Test runner

Ready to run.

Testing in
TestOps/sec
byId
document.getElementById("Hello");
ready
by Window bracket
window["Hello"];
ready
by direct window
window.Hello;
ready

Revisions

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