摘要: 3、内部对象 判断对象 typeof > typeof undefined "undefined" > typeof 1 "number" > typeof 'aaaa' "string" > typeof true "boolean" 3.1 Date var now = new Date(); 阅读全文
posted @ 2021-02-28 19:08 仙贝wang 阅读(58) 评论(0) 推荐(0)
摘要: 2.函数 函数和方法的区别: 函数:是可以执行的JavaScript代码块,由JavaScript程序定义或JavaScript实现预定义。 方法:是通过对象调用的JavaScript函数。方法也是函数,只是比 较特殊的函数。 实际比较起来,函数和方法差别不大。 2.1 定义函数 以定义绝对值函数为 阅读全文
posted @ 2021-02-28 19:05 仙贝wang 阅读(99) 评论(0) 推荐(0)