js筛选数组排除多个多个不符合项
const arr = [ { label: '2', value: '2' }, { label: '1', value: '1' }, { label: '3', value: '3' } ] // 把value=1和value=2的数据筛掉 let newArr = arr.filter(opt => ['1', '2'].includes(opt.value) ) console.log(newArr) // [{label: '3', value: '3'}]