摘要: 1.获取当前时间 // console.log(new Date().getTime()); 获取当前时间的毫秒数 // console.log(new Date()); 获取当前的时间 let date = new Date(); let year = date.getFullYear(); le 阅读全文
posted @ 2022-09-30 12:41 孙凯a 阅读(988) 评论(0) 推荐(0) 编辑
摘要: 箭头函数的使用以及和普通函数之间的转换 // 第一种不带参数 // var one = function(){ // return 'I am one' // } var one = ()=> 'I am one' console.log(one()) // 第二种 带一个参数 // var two 阅读全文
posted @ 2022-09-30 10:48 孙凯a 阅读(10) 评论(0) 推荐(0) 编辑