typeof运算符

javascript中typeof用来判断一个变量或表达式的数据类型。

typeof 返回值有六种可能: "number," "string," "boolean," "object," "function," 和 "undefined."

 

参考:http://www.zgguan.com/zsfx/jsjc/6397.html

 

posted @ 2016-09-19 10:45  ximi007  阅读(163)  评论(0编辑  收藏  举报