上一页 1 ··· 28 29 30 31 32 33 34 35 36 ··· 61 下一页
摘要: // 1 Number.EPSILON 是 js 表示最小精度 // console.log(Number.EPSILON); // 2.220446049250313e-16 // console.log(0.1 + 0.2); // 0.30000000000000004 // // 判断两个数 阅读全文
posted @ 2021-05-18 23:09 13522679763-任国强 阅读(45) 评论(0) 推荐(0)
摘要: // es6 实现继承 class Phone{ // 构造方法 constructor(brand,price){ this.brand = brand; this.price = price; } // 父类 成员属性 call(){ console.log('可以打电话'); } } // 智 阅读全文
posted @ 2021-05-18 22:45 13522679763-任国强 阅读(36) 评论(0) 推荐(0)
摘要: // es6 实现继承 class Phone{ // 构造方法 constructor(brand,price){ this.brand = brand; this.price = price; } // 父类 成员属性 call(){ console.log('可以打电话'); } } // 智 阅读全文
posted @ 2021-05-18 22:42 13522679763-任国强 阅读(72) 评论(0) 推荐(0)
摘要: // es5 实现继承 // 手机 function Phone(brand,price){ this.brand = brand; this.price = price; } // 添加方法 Phone.prototype.call = function(){ console.log('可以打电话 阅读全文
posted @ 2021-05-18 22:35 13522679763-任国强 阅读(48) 评论(0) 推荐(0)
摘要: // 手机 // function Phone(){ // } // Phone.name = '手机'; // Phone.change = function(){ // console.log('可以改变世界'); // } // Phone.prototype.size = '5.5inch' 阅读全文
posted @ 2021-05-18 22:33 13522679763-任国强 阅读(61) 评论(0) 推荐(0)
摘要: // 手机 // function Phone(brand,price){ // this.brand = brand; // this.price = price; // } // // 添加方法 // Phone.prototype.call = function(){ // console.l 阅读全文
posted @ 2021-05-18 22:32 13522679763-任国强 阅读(32) 评论(0) 推荐(0)
摘要: let m = new Map(); // 添加元素 m.set('name','Eric'); m.set('change', function(){ console.log('逆天改命...'); }); let key = { school :'ATBEIDA' } m.set(key,['北 阅读全文
posted @ 2021-05-18 21:55 13522679763-任国强 阅读(36) 评论(0) 推荐(0)
摘要: // 声明一个 set let s = new Set(); let s2 = new Set(['大事','小事','好事','坏事','小事']); // console.log(s, typeof s); // console.log(s2); // Set(4) {"大事", "小事",&# 阅读全文
posted @ 2021-05-17 21:51 13522679763-任国强 阅读(22) 评论(0) 推荐(0)
摘要: 基础 const p = new Promise(function(resolve,reject){ setTimeout(() => { // let data = '数据库中的用户数据'; // resolve(data); let err = '数据读取失败'; reject(err) },  阅读全文
posted @ 2021-05-17 21:17 13522679763-任国强 阅读(102) 评论(0) 推荐(0)
摘要: // // 函数代码分隔符 // function * gen(){ // // console.log('hello generator'); // } // let iterator = gen(); // // console.log(iterator); // // iterator.nex 阅读全文
posted @ 2021-05-17 12:19 13522679763-任国强 阅读(51) 评论(0) 推荐(0)
上一页 1 ··· 28 29 30 31 32 33 34 35 36 ··· 61 下一页