js 判断数组的7 种方法
Posted Apple
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了js 判断数组的7 种方法相关的知识,希望对你有一定的参考价值。
1. Array.isArray([]) // true 2. Object.prototype.toString.call([]) // '[object Array]' 3. [].constructor Array // true 4. [] instanceof Array // true
以上是关于js 判断数组的7 种方法的主要内容,如果未能解决你的问题,请参考以下文章