Blogger Information
Blog 10
fans 0
comment 0
visits 12465
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
js 数据类型判断方法
Andy001
Original
702 people have browsed it

js 数据类型判断

typeof 判断

  • typeof 能判断,数字,字符串,布尔值,undefined,function,不能判断Object,Array,Funtion,mull.

    instanceof 判断

  • instanceof 用来判断 Object,Array,Function 的真假

    === 判断

  • === 用来判断一个数据类型是否为null
    1. let a = null
    2. console.log (a === null)


Statement of this Website
The copyright of this blog article belongs to the blogger. Please specify the address when reprinting! If there is any infringement or violation of the law, please contact admin@php.cn Report processing!
All comments Speak rationally on civilized internet, please comply with News Comment Service Agreement
0 comments
Author's latest blog post