一个简单易懂的js数组去重表达式

34 阅读1分钟
const arr = [1,2,3,3,4,5,6,7]
const result = Array.from(new Set(arr)) //result:[1,2,3,4,5,6,7]