I am working for my study on a React Native project, with group members. My group member who made the project has no problems running the project. I have expo installed globally, but can not run the program:
Unable to find expo in this project - have you run yarn / npm install yet?
├─ action C:\Users\thoma\AppData\Roaming\npm\node_modules\expo-cli\src\commands\start.ts:34:11
├─ C:\Users\thoma\AppData\Roaming\npm\node_modules\expo-cli\src\commands\start.ts:135:22
└─ expo start C:\Users\thoma\AppData\Roaming\npm\node_modules\expo-cli\src\exp.ts:350:7
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @ start: `expo start`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @ start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm WARN Local package.json exists, but node_modules missing, did you mean to install?
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\thoma\AppData\Roaming\npm-cache\_logs\2021-06-07T11_27_47_082Z-debug.log
What can I do to solve this?
At the root of your project, Run command
yarn
So basically your partner would have added few dependencies and committed his code. Now after fetching you need to have those dependencies in your project which is why you would have to run above command.
You can also use npm install
, depending upon your system configurations.