随笔分类 - ES8
ES8新特性
摘要:// 声明对象 const school = { name: "上海华师大", cities: ['上海','北京','深圳'], skill: ['java','php','vue'] } Object.keys(school) // ["name", "cities", "skill"] Obj
阅读全文
摘要:const fs = require('fs'); // 读取文件 function readStudy() { return new Promise((resolve,reject) = >{ fs.readFile("./resoureces/style.md",(err,data)=>{ //
阅读全文
摘要:1.await 必须要在 async中使用 // 创建 promise 对象 (成功) const p = new Promise((resolve, reject)=>{ resolve('用户数据') }) // await 要放在 async 函数中使用 async function main
阅读全文
摘要: ### 
阅读全文