-
Notifications
You must be signed in to change notification settings - Fork 27.3k
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 does not use custom directories from next.config.js #26393
Comments
Attempt to fix vercel#26393 Sorry, I wasn't able to run tests on local, but I hope at least unit test should be valid.
Attempt to fix vercel#26393 Sorry, I wasn't able to run tests on local, but I hope at least test should be valid.
Same issue, but the document Linting Custom Directories describes only for production builds |
@nghiepit
thanks for pointing this out, I have completely missed that, and it has no sense for me, use custom directories only for production build. This is how I noted the issue. Hopefully it will be accepted and fixed. |
Attempt to fix vercel#26393 Sorry, I wasn't able to run tests on local, but I hope at least test should be valid.
Same here. Any workaround to not use next build to discover the linting issues? |
Attempt to fix vercel#26393 ~~Sorry, I wasn't able to run tests on local, but I hope at least test should be valid.~~ Edit: Tests are working correctly on my local :) fixes vercel#26393 ## Bug - [x] Related issues linked using `fixes vercel#26393` - [x] Integration tests added
This issue has been automatically locked due to no recent activity. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you. |
What version of Next.js are you using?
11.0.0
What version of Node.js are you using?
16.1.0
What browser are you using?
not important
What operating system are you using?
macOS
How are you deploying your application?
not important
Describe the Bug
Custom directories for linting are not used when running
next lint
, but only when runningnext build
We are missing eslint.dirs somewhere:
next.js/packages/next/cli/next-lint.ts
Lines 133 to 142 in 0ca2456
as we have it here:
next.js/packages/next/build/index.ts
Line 217 in 0ca2456
Related to: #25895
Expected Behavior
Custom directories for linting are used also on
next lint
run.To Reproduce
Create project and configure any custom directory in
next.config.js
, put there any file with some obvious issues and try to run linter.It's not going to fail with
next lint
, but only withnext build
.The text was updated successfully, but these errors were encountered: