cartant / eslint-plugin-rxjs

ESLint rules for RxJS
MIT License
312 stars 37 forks source link

[enhancement] `ban-operators` report the use instead of the import #96

Open spali opened 2 years ago

spali commented 2 years ago

I like to ban some operators to rethink the use of it like switchMap and withLatestFrom usually use concatMap and a concatLatestFrom (from ngrx) instead. For switchMap there exist a specific rule, but not for others. The problem I have, if I use ban-operators for these, I can not make exceptions by ignoring them on the line they are used, but have to ignore the rule on the import. It would help if ban-operators would report the use of the operator's instead of the import.

JasonWeinzierl commented 1 day ago

I've implemented this change in forked package eslint-plugin-rxjs-x.