ES6 新语法新特性总结中...
1. 感觉 for of 通杀 for循环 和 for in呢
aaa 可以是array /object
for (let k of aaa) {
console.log(k)
}
2. 数组合并 [...array1,...array2]
3 简单数组去重
let aaa = [
'1633719303092','1633719303092','1633715699760','1633715699760','1633715699760','1633715699760',
'1633715699760','1633715699760','1633715699760','1633712096528','1633712096528','1633712096528',
'1633712096528','1633712096528','1633712096528','1633712096528','1633708493380','1633708493380',
'1633708493380','1633708493380','1633708493380','1633708493380'
];
let b = new Set(aaa);
console.log(Array.from(b));