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

react version "detect-no-warn" #2717

Closed
aminya opened this issue Jul 19, 2020 · 1 comment
Closed

react version "detect-no-warn" #2717

aminya opened this issue Jul 19, 2020 · 1 comment

Comments

@aminya
Copy link

aminya commented Jul 19, 2020

I want to use a single Eslint configuration for multiple projects. However, some of the projects do not use react. When I set the react version settings to detect, I get a warning that react is not installed in those repositories.

  "settings": {
    "react": {
      "version": "detect"
    }
  }

I wish there was an option to set the version to "version": "detect-no-warn", so I can use a single Eslint preset for all of the projects no matter if they are using react or not.

@ljharb
Copy link
Member

ljharb commented Jul 19, 2020

This is a duplicate of #2276.

tl;dr: if they're not using react, they shouldn't be using any eslint-plugin-react rules. It's simply not tenable to have a single preset that works for both react and non-react, which is why the airbnb styleguide doesn't do it.

@ljharb ljharb closed this as completed Jul 19, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging a pull request may close this issue.

2 participants