object.hasownproperty

Benchmark created by Sean Koole on


Preparation HTML

<script>
  var o = {};
  
  for (var i = 1000; i--;)
  o[i] = i;
</script>

Test runner

Ready to run.

Testing in
TestOps/sec
o.hasOwnProperty
for (var name in o) {
 if (o.hasOwnProperty(name)) {
  // ..
 }
}
ready
no .ohasOwnProperty
for (var name in o) {
 // ..
}
ready

Revisions

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

  • Revision 1: published by Sean Koole on