摘要: <!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Document< 阅读全文
posted @ 2020-05-16 15:09 我是乐呀 阅读(137) 评论(0) 推荐(0)
摘要: 函数的声明 函数的声明 console.log(fn); fn(); 普通函数声明 function fn(){ console.log("aaa"); } 匿名函数声明 var fn=function(){ console.log("bbb"); } fn(); 普通函数声明,当进入该script 阅读全文
posted @ 2020-05-16 09:31 我是乐呀 阅读(115) 评论(0) 推荐(0)
摘要: 知识点总结: 1、普通函数中的this 在普通函数中,this是表示window console.log(this)function abc(){ console.log(this);function a(){ console.log(this);}a();}abc(); 2、事件中的this 在事 阅读全文
posted @ 2020-05-16 09:21 我是乐呀 阅读(223) 评论(0) 推荐(0)