Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/86.0.4240.77 YaBrowser/20.11.0.918 Yowser/2.5 Safari/537.36
Yandex Browser 20
Mac OS X 10.15.7
Desktop
4 years ago
Test name Executions per second
Array.isArray 10590463.0 Ops/sec
instanceof 3288473.0 Ops/sec
[].constructor 3405203.5 Ops/sec
Object.prototype.toString 4745661.5 Ops/sec
Script Preparation code:
Tests:
  • Array.isArray

  • instanceof

  • [].constructor

  • Object.prototype.toString