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

Rule 'jsx-uses-vars': why not on by default? #49

Closed
banderson opened this issue Mar 31, 2015 · 6 comments · Fixed by #51
Closed

Rule 'jsx-uses-vars': why not on by default? #49

banderson opened this issue Mar 31, 2015 · 6 comments · Fixed by #51
Labels

Comments

@banderson
Copy link
Contributor

Thanks for this plugin! Very cool.

I'm thinking about adopting this for my default setup across the org, but just wondering why jsx-uses-vars wouldn't be turned on by default (maybe to 'warn')? I guess the real question is: what's the use case for not wanting to mark them used?

Also, I'm totally willing to PR a change, but just wanted to get your feedback first. And if the consensus is no rule should be on by default, can we invert the language of the rule to something like jsx-ignore-var-usage?

@yannickcr
Copy link
Member

Hi, there is no particular reason why this rule turned off by default.

It's just historical: I progressively added rules to the plugin and all new rules were added off by default.

We could totally turn it on by default since this rule has no effect if the no-unused-vars ESLint rule is not enabled.

@hexpunk
Copy link

hexpunk commented Apr 3, 2015

👍 for this turned on by default

@banderson
Copy link
Contributor Author

@yannickcr would you like me to PR this change?

@yannickcr
Copy link
Member

You can do a PR for this :)

@schickling
Copy link

I would even go a step further an switch on all features that "make sense" by default and release a new version with those "breaking changes". I find my self copying all those config stuff in the .eslintrc files currently.

@banderson
Copy link
Contributor Author

@schickling that's definitely a good conversation to have with @yannickcr , but I just PR'd this one change for now. I'd be glad to help out with further changes if that's what's decided.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging a pull request may close this issue.

4 participants