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

Automatic fix for unused private members #952

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

pamelalozano16
Copy link
Contributor

@pamelalozano16 pamelalozano16 commented Jan 22, 2024

Automatic fix for no-unused-private-members

@kristerkari
Copy link
Collaborator

Thanks!

I think that it's a bit tricky to add autofix for this rule. The autofix will delete styles, which might not always be what the user expects to happen.

Should something like this be instead implemented with an extra option that you can opt-in to using when you want the styles to be automatically fixed?

@pamelalozano16
Copy link
Contributor Author

Gotcha, what about a config option like allowAutoFix: true ?

@kristerkari
Copy link
Collaborator

what about a config option like allowAutoFix: true

I was trying to search stylelint's repo to see if they have anything similar there, but it seems that there are no autofixes like this (that remove code). I'm not even 100% sure if adding an autofix like this is a good idea since it needs to be enabled with a secondary option.

Another option for the option name could be enableAutoFix.

@pamelalozano16
Copy link
Contributor Author

pamelalozano16 commented Mar 5, 2024

@kristerkari Just added enableAutoFix as a secondary option

@pamelalozano16 pamelalozano16 force-pushed the new-lint branch 2 times, most recently from 0e8b7b0 to 353e633 Compare April 4, 2024 17:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants