- typeof(判断简单类型):
undefined
null
string
number
boolean
- instanceof(判断是否是某个对象的实例):
String()
Object()
Boolean()
Number()
RegExp()
undefined
null
string
number
boolean
String()
Object()
Boolean()
Number()
RegExp()
上一篇:html5使用svg步骤
充分利用ChatGPT的优势,帮助我们快速准备前端面试。今日问题:instanceof与typeof的区别?
举报文章
请选择举报类型
补充说明
0/200
上传截图
格式支持JPEG/PNG/JPG,图片不超过1.9M