Home > Back-end >  Unable to find expo in this project - have you run yarn / npm install yet? Npm has been installed, e
Unable to find expo in this project - have you run yarn / npm install yet? Npm has been installed, e

Time:12-23

My Expo project is pretty much 9999999% errors thus far, and it finally reached its climax when it decided to throw an error I've never heard of at me:

module not found: can't resolve '../utilities/platform'

I've never seen this, and I was explicitly working in an isolated styling file when it occurred. I deleted the file and the error persisted. Seeing that it was in node_modules, I figured that deleting node_modules would be helpful. It wasn't. I deleted the node_modules and tried to run npm i --save afterwards but it kept erroring out. I restarted my computer, deleted the new node_modules, and tried to run npm i --save yet again. This time I was greeted with this:

read-shrinkwrap This version of npm is compatible with lockfileVersion@1, but package-lock.json 
was generated for lockfileVersion@2. I'll try to do my best with it!
npm ERR! Maximum call stack size exceeded

Now, I have a half(ish) completed node_modules, and whenever I try to run expo start, which I have about 700000000 times before this, it tells me this...

Unable to find expo in this project - have you run yarn / npm install yet?

Which, yes stupid I have my expo set up, and yes AGAIN, I just ran npm install about twenty-two times. So I have absolutely no idea what happened, why it happened, or how to fix whatever happened. If you can help me I will award you my first born but fair warning that might take another 20 years

CodePudding user response:

Try to remove all react-native data folders from "%appdata%\Temp" and execute following commands:

cd android (if any)

gradlew clean

cd.. and remove the node_modules folder

npm cache clean --force

npm install

npm start -- --reset-cache
  • Related