question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

"next lint" can't find eslint

See original GitHub issue

What version of Next.js are you using?

11.1.2

What version of Node.js are you using?

v14.18.1

What browser are you using?

N/A

What operating system are you using?

Windows 10

How are you deploying your application?

local dev

Describe the Bug

Running “yarn lint” produces error output:

> yarn lint
$ next lint
info  - Using webpack 5. Reason: Enabled by default https://nextjs.org/docs/messages/webpack5
error - ESLint must be installed: yarn add --dev eslint
Done in 2.79s.

eslint is installed and running the suggested command doesn’t change the result

Expected Behavior

The linter runs

To Reproduce

npx create-next-app . yarn lint

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
RobertSandifordcommented, Oct 16, 2021

I think this is a duplicate of #29961. A workaround is to downgrade eslint to 7.32.0

Yes it is. Nothing came up on a search.

Thanks

1reaction
gaston-florescommented, Oct 16, 2021

I think this is a duplicate of #29961. A workaround is to downgrade eslint to 7.32.0

Read more comments on GitHub >

github_iconTop Results From Across the Web

Can't run next lint because ESLint can't be found #29951
I'm trying to run the default NextJS linter as described here, but the system is having trouble finding ESLint, even though it's installed....
Read more >
Basic Features: ESLint - Next.js
You can now run next lint every time you want to run ESLint to catch errors. Once ESLint has been set up, it...
Read more >
next.js Setting up ESLint for NextJs - Stack Overflow
To test if linting works run eslint command in terminal with folder path i.e. eslint pages/** and notice output. To disable linting of...
Read more >
Troubleshooting a Next.js app with ESLint - LogRocket Blog
Setting up ESLint with Next.js. Inside your Next.js app, add a new script called lint — its value should be next lint :...
Read more >
Configure ESLint for Next.js - Devin Shoemaker
Generate ESLint Config · Select To check syntax and find problems · Select JavaScript modules as the type of module your project uses...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found