huyueshan

导航

2019年5月11日 #

js简洁模式代码

摘要: 1 // 创建过去七天的数组,如果将代码中的减号换成加号,你将得到未来7天的数组集合 2 [...Array(7).keys()].map(days => new Date(Date.now() - 86400000 * days)); 3 4 // 生成长度为11的随机字母数字字符串 5 Math.random().toString(36).substring(2); 6 7... 阅读全文

posted @ 2019-05-11 22:09 huyueshan 阅读(313) 评论(0) 推荐(0) 编辑