随笔分类 - EX6
摘要:this和super: super( ) EX6类的继承, 在react中官方固定应用 在java面向对象思想中这样定义: this表示当前对象,this()为当前对象的其他构造函数 super表示父类对象,super()为父类对象的其他构造函数
阅读全文
摘要:ES5: function article(x,y){ this.x = x; this.y = y; } article.prototype.say = function() { return (this.x + "的年纪=" + this.y) } var person = new articl
阅读全文
摘要:1. Object.is( ); //用来判断,不同等 == 与 接近。NaN作出的调整 let obj={a:1,b:2}; Object.is(obj,obj);//true Object.is(obj,{obj});//false Object.is({},{});//false Object
阅读全文
摘要:let str = "my string"; 1. str.startsWith('my'); //true2.str.endsWith('my'); //false3.str.includes('str'); //true4.str.repeat(3); //'my string my strin
阅读全文
摘要:1. 回掉2. promise3. Generator4. Async/await
阅读全文
摘要:1. 字符串模板 2. 箭头函数 3. 变量 let 与 var ,let定义在 for{ let name = "jay"; } 外面取不到,var 可以取得 const 不可变 4. 展开 function hello( name1, name2){ console.log(name1, nam
阅读全文

浙公网安备 33010602011771号