数据类型分类: 原始(基本、简单)数据类型:5种 number string boolean undefined 空(null) 引用(复杂)数据类型:object function … 检测数据类型: typeof(需要检测的内容) 返回几种值(7种):function number string boolean undefined object symbol(ES6中新增的) var a=‘abcd’ console.log(typeof(a)) 控制台输出:string