jjw

写给自己的博客。 记录学习的点滴以备查。
随笔 - 127, 文章 - 0, 评论 - 8, 阅读 - 62632
  博客园  :: 首页  :: 新随笔  :: 联系 :: 订阅 订阅  :: 管理
< 2025年3月 >
23 24 25 26 27 28 1
2 3 4 5 6 7 8
9 10 11 12 13 14 15
16 17 18 19 20 21 22
23 24 25 26 27 28 29
30 31 1 2 3 4 5

随笔分类 -  JavaScript

摘要:1、函数被当作函数使用(调用)时,函数的可以说是没有this的,因为这个this就是window。 当 f() 调用时,就相当于window.f(),所以this指向window。无论是在任何地方调用函数!(除apply, bind, call方式外) 2、函数被当作构造函数用时,this指向new 阅读全文

posted @ 2022-11-29 17:40 jjw 阅读(31) 评论(0) 推荐(0) 编辑

摘要:一、原型链的由来 在java,c#等语言中,所有的对象类型都可以从下到上追溯到object上,而javascript中也有这种机制 原型链。 JS的原型链类似 数据结构的链表, prototype类似节点,__proto__类似 next 指针,这里在网上找了个图片。 二、__proto__ 和 p 阅读全文

posted @ 2022-02-20 15:47 jjw 阅读(110) 评论(0) 推荐(0) 编辑

摘要:console.log(Object.__proto__ Function.prototype);//true console.log(Function.__proto__ Function.prototype);//true console.log(Object.__proto__ Functio 阅读全文

posted @ 2020-11-26 20:24 jjw 阅读(88) 评论(0) 推荐(0) 编辑

摘要:async play() { let upload = document.getElementById("file1"); let f = upload.files[0]; var ctx = new AudioContext(); var source = ctx.createBufferSour 阅读全文

posted @ 2020-11-08 21:53 jjw 阅读(81) 评论(0) 推荐(0) 编辑

摘要:methods: { async upfile() { let upload = document.getElementById("file1"); let f = upload.files[0]; let size = 1024 * 100; let start = 0, end = 0; let 阅读全文

posted @ 2020-11-08 16:40 jjw 阅读(178) 评论(0) 推荐(0) 编辑

摘要:procedure TWebModule1.WebModuleBeforeDispatch(Sender: TObject; Request: TWebRequest; Response: TWebResponse; var Handled: Boolean); begin if UpperCase 阅读全文

posted @ 2020-11-06 22:57 jjw 阅读(190) 评论(0) 推荐(0) 编辑

摘要:try {// http.post 调用 updatelogin 方法 http.get 调用 login 方法 const { data: res } = await this.$http.post('/TSM/login/', { _parameters: [this.loginForm.use 阅读全文

posted @ 2020-02-19 14:59 jjw 阅读(409) 评论(0) 推荐(0) 编辑

摘要:引自 https://www.cnblogs.com/huangwentian/p/6854472.html#commentform ① this指向的,永远只可能是对象! ② this指向谁,永远不取决于this写在哪!而是取决于函数在哪调用。 ③ this指向的对象,我们称之为函数的上下文con 阅读全文

posted @ 2019-03-30 00:06 jjw 阅读(136) 评论(0) 推荐(0) 编辑

摘要:对象有 __proto__ 函数有 prototype 对象的__proto__指向构造自己的函数的prototype 但有一例外 var Obj = {v:99}var pObj = Object.create(Obj);console.log(pObj.__proto__ Obj) // tru 阅读全文

posted @ 2017-08-19 22:15 jjw 阅读(302) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示