I'm trying to avoid multiple logical OR conditional checks with ||
using includes. Could anyone please help how to achieve that using array's include method?
const cars = [{
name: 'BMW',
year: '2020'
}, {
name: 'Audi',
year: '2019'
}, {
name: 'Benz',
year: '2018'
}]
const result = cars.includes(['BMW', 'Audi'])
console.log(result);