const arr = ['be-', 'fe-', 'automated'];
const str = 'fe-cheese';
const oi = arr.includes(str) ? 'cheese' : 'meat';
console.log(oi);
I have an array of partial matches and I want to check to see if the string contains any of the partials in the arr.
The above returns meat when it should match fe- and return cheese