-
-
Notifications
You must be signed in to change notification settings - Fork 27k
Cannot find module 'eslint/lib/formatters/stylish' #3617
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
Comments
I had the same issue. I solved it by just installing eslint in the project: npm install eslint -S |
Please provide My guess is you tried to install
This will cause further issues. Please don't do this unless you've ejected and know what you're doing. |
Ran into the same issue! I tried installing eslint in my local project. Now even after being removed my build is broken. Did what @eltoro did and it solved it. {
"name": "backdrop-finder",
"version": "0.1.0",
"private": true,
"dependencies": {
"apollo-cache-inmemory": "^1.1.0",
"apollo-client": "^2.0.2",
"apollo-link-http": "^1.1.0",
"eslint": "^4.13.1",
"graphql": "^0.11.7",
"graphql-tag": "^2.5.0",
"mapbox-gl": "^0.41.0",
"mapbox-gl-geocoder": "^2.0.1",
"polished": "^1.9.0",
"react": "^16.0.0",
"react-amplitude": "0.0.6",
"react-apollo": "^2.0.1",
"react-dom": "^16.0.0",
"react-instagram-embed": "^1.3.2",
"react-mapbox-gl": "^2.7.0",
"react-router-dom": "^4.2.2",
"react-scripts": "1.0.17",
"styled-components": "^2.2.3"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test --env=jsdom",
"eject": "react-scripts eject"
}
} |
It's not supported to try to install these tools into a project managed by I'll close this one as it seems to be caused by a misunderstanding of how CRA works. |
I removed Fixed it for me |
@eltoro |
I uninstalled eslint from my project with no luck. Only thing that worked for me was installing eslint into my dependencies rather than my devDependencies. |
If you haven't ejected and see this problem:
|
Hi,
I found some strange issue to me:
Failed to compile.
./src/index.js
Module build failed: Error: Cannot find module 'eslint/lib/formatters/stylish'
What I did is just create app by using
create-react-app myapp-name
and that worked fine.After that I had to push the project to repository and erase my mac disk image in order to install fresh copy of macOS image (due to some OS problems). Now I have everything fresh and after cloning repo, running
npm i
and thennpm start
I get mentioned message.Moreover I tested it on newly created project and build works - for my app that I work on - does not.
I tried to test some case and steps like following:
create-react-app myapp
cd myapp
rm -rf node_modules/
cd ..
mv myapp otherapp
cd otherapp/
npm i
npm start
are good example to reproduce described issue.
My node version is:
9.3.0
.Trying it with
4.x
and nothing changed.Do you have some quick tip how to resolve it ?
Thanks.
The text was updated successfully, but these errors were encountered: