instanceof vs isArray

Benchmark created on


Setup

let arr = [1, 2, 3];

Test runner

Ready to run.

Testing in
TestOps/sec
instanceof
arr instanceof Array
ready
isArray
Array.isArray(arr)
ready

Revisions

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