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

eslint --init does not add settings as required by #1955 #3256

Closed
AlbinoGeek opened this issue Mar 23, 2022 · 2 comments
Closed

eslint --init does not add settings as required by #1955 #3256

AlbinoGeek opened this issue Mar 23, 2022 · 2 comments

Comments

@AlbinoGeek
Copy link

Hello!

So, why does eslint --init ask me if I'm using React, if it doesn't bother to add settings as required by #1955 ?

Maybe this issue belongs in eslint repository itself? But why does it have options for React? Who's responsible for that piece?

It literally only needs to add the following:

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

I expect initializers to give you a known-good/working configuration, it currently does not.

@ljharb
Copy link
Member

ljharb commented Mar 23, 2022

That is not a reasonable expectation, but yes, I’d file it on eslint itself.

@AlbinoGeek
Copy link
Author

That is not a reasonable expectation, but yes, I’d file it on eslint itself.

I'd like to understand what you mean by this.

eslint --init configures your project based on an interactive questionaire

One of the questions has you select React as your framework, and it changes your generated configuration.

Why and how would it be unreasonable to expect it, when it generates configuration, to generate one extra directive to make it work out of the box?

I will lodge the issue over there.

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

No branches or pull requests

2 participants