-
-
Notifications
You must be signed in to change notification settings - Fork 26.9k
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
Vague error when eslintrc.js is invalid #7552
Comments
This issue has been automatically marked as stale because it has not had any recent activity. It will be closed in 5 days if no further activity occurs. |
Still reproducible on the latest master. |
Looks like the PR fixed it somewhat. This now shows the following error:
That's presumably the error eslint throws. However from the error it's not clear what the actual problem is and how to fix it. |
This issue has been automatically marked as stale because it has not had any recent activity. It will be closed in 5 days if no further activity occurs. |
This issue has been automatically marked as stale because it has not had any recent activity. It will be closed in 5 days if no further activity occurs. |
This issue has been automatically marked as stale because it has not had any recent activity. It will be closed in 5 days if no further activity occurs. |
This issue has been automatically closed because it has not had any recent activity. If you have a question or comment, please open a new issue. |
Not stale. I was just out for vacation. |
Describe the bug
When a project has an invalid
.eslintrc.js
and is started withEXTEND_ESLINT=true
create-react-app will fail to compile.Did you try recovering your dependencies?
Not sure if applicable since this happens in a newly generated project too.
Which terms did you search for in User Guide?
I mostly looked at which does not mention existing
.eslintrc.js
https://create-react-app.dev/docs/setting-up-your-editor#displaying-lint-output-in-the-editorEnvironment
Steps to reproduce
npx create-react-app eslint-test
cd eslint-test
touch .eslintrc.js
(or.eslintrc.json
,.eslintrc.yml
)EXTEND_ESLINT=true yarn start
Note that in step 3 the contents of eslintrc doesn't matter. A valid eslintrc will also fail.Edit: This is a bit more nuanced. The following works:
This does not:
but this does:
Expected behavior
The server to startEdit: I expect to see an error about an invalid eslintrc. Perhaps suggesting that
react-app
needs to be extended.Actual behavior
Compile errors like
Reproducible demo
https://github.com/klaaspieter/create-react-app-eslintrc
Steps to reproduce:
git clone https://github.com/klaaspieter/create-react-app-eslintrc.git
cd create-react-app-eslintrc
yarn
(Note thatyarn.lock
changes, is this a separate issue?)EXTEND_ESLINT=true yarn start
The text was updated successfully, but these errors were encountered: