`unicorn/no-array-callback-reference` does not report when optional chaining
czizzy opened this issue · comments
Izzy Chen commented
this rule is not reported when optional chaining
unicorn/no-array-callback-reference
function isString(arg) {
return typeof arg === 'string';
}
const obj = { a: [], b: [] };
obj.a.filter(isString);
obj.b?.filter(isString);
only the first filter report an error.
fisker Cheung commented
Remove this line should fix this
PR welcome.