Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move removed rules to deprecated section #245

Merged
merged 5 commits into from Mar 12, 2023
Merged

Move removed rules to deprecated section #245

merged 5 commits into from Mar 12, 2023

Conversation

regseb
Copy link
Contributor

@regseb regseb commented Mar 7, 2023

Move many rules to deprecated section:

@regseb regseb changed the title Move generator-star to deprecated Move many rules to deprecated section Mar 7, 2023
@lydell
Copy link
Member

lydell commented Mar 7, 2023

Awesome work!

How did you manage to find all of these? Did you run some tool?

@regseb
Copy link
Contributor Author

regseb commented Mar 7, 2023

I'm currently adding Prettier to my project so I'm using eslint-config-prettier to know which ESLint rules to disable. When eslint-config-prettier disables a rule that I don't have in my configuration: I checked that it's removed and moved it to the deprecated section.

@lydell
Copy link
Member

lydell commented Mar 7, 2023

Ok!

Just checking one more thing: Do you have a practical need for this, or did you make the PR more for like “correctness sake”?

@regseb
Copy link
Contributor Author

regseb commented Mar 7, 2023

I will not install the eslint-config-prettier dependency in my project. I use eslint-config-prettier as reference. I propose this PR to make my configuration consistent with the configuration of eslint-config-prettier.

@lydell
Copy link
Member

lydell commented Mar 7, 2023

I see! I think. It’s fine to use eslint-config-prettier just as a reference – I do that too in many projects.

How does this PR help you use eslint-config-prettier as a reference?

(Not questioning the validity of the PR, just trying to figure out the impact of this PR if any.)

@regseb
Copy link
Contributor Author

regseb commented Mar 7, 2023

Reference, in the meaning of documentation.

  • To know all the rules of ESLint, I would go to the Rules Reference page.
  • To know the rules to disable with Prettier, I would look the index.js file of eslint-config-prettier.

@lydell
Copy link
Member

lydell commented Mar 7, 2023

The index.js file of eslint-config-prettier contains the same set of rules both before and after this PR.

In other words, you haven’t explained how you use the information about which rules are deprecated in eslint-config-prettier.

@regseb
Copy link
Contributor Author

regseb commented Mar 7, 2023

My configuration has all ESLint rules (except deprecated or removed).

I looked all the rules in the index.js files (except the includeDeprecated ones) and set them to "off" in my configuration. When I got to the generator-star rule, I was surprised not to find it in my configuration. I checked the documentation and discovered that it was removed. With this PR, the deprecated and removed rules are grouped together in includeDeprecated so I can ignore them.

@lydell lydell changed the title Move many rules to deprecated section Move removed rules to deprecated section Mar 12, 2023
@lydell lydell merged commit 130bf88 into prettier:main Mar 12, 2023
@regseb regseb deleted the patch-1 branch April 18, 2023 18:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants