sarbbottam / eslint-find-rules

Find built-in ESLint rules you don't have in your custom config
http://npm.im/eslint-find-rules
MIT License
201 stars 33 forks source link

I'm not sure how to deal with renamed rule in ESLint 7.4.0 #326

Closed ronkorving closed 4 years ago

ronkorving commented 4 years ago

Hi there, love this project, thanks so much for your work!

I noticed that in ESLint 7.4.0 the rule id-blacklist was renamed to id-denylist. However, no matter which rule I configure for, when I run eslint-find-rules now, it will either complain to me that I'm not using one or the other. Both seem to co-exist (at least in the eyes of eslint-find-rules).

This may not be an issue with eslint-find-rules, but is there perhaps a difference in how ESLint does deprecation vs. how this package deals (or not) with cases like this? Any advice?

https://github.com/eslint/eslint/releases/tag/v7.4.0

ljharb commented 4 years ago

The old name should still work throughout eslint 7.

You wouldn’t be able to use the new name until you no longer supported eslint < v7.4.

ljharb commented 4 years ago

(and when you do use the new one, you’d specify the old one as “off” explicitly)

ronkorving commented 4 years ago

That actually makes total sense. Thanks so much!

ronkorving commented 3 years ago

@ljharb I understand that in the latest ESLint id-blacklist is officially deprecated. I guess that makes this problem go away "properly"? :)

ljharb commented 3 years ago

@ronkorving being "deprecated" just means they'll remove it in eslint v8, which means supporting eslint v8 will be a breaking change for shared configs, so at that point they'd probably drop support for eslint < v7.4.

ta2edchimp commented 3 years ago

Is it really a breaking change for eslint-find-rules? I‘d agree it is for eslint configs (using this particular rule), but for this tool it is only dealing with a changed set of available rules, the same as if an eslint plugin would have been removed / replaced / added.

ljharb commented 3 years ago

@ta2edchimp oh sorry, forgot which repo I'm in :-) it's not a breaking change at all for eslint-find-rules; but it'd be a breaking change for the airbnb eslint config.