Signup/Sign In
Ask Question
Not satisfied by the Answer? Still looking for a better solution?

Sh: react-scripts: command not found after running npm start

I cloned a react application onto my system and ran following commands
npm install -g create-react-app
npm install --save react react-dom


After that i ran
npm start 

But it threw the above mentioned error, It is working fine on my other system from which i pushed it on github. But it is not working on any other system after cloning whether windows or mac.
by

2 Answers

espadacoder11
Solution
run npm install (or yarn) to ensure all deps are downloaded.

Alternative Solution
If node_modules exists, remove it with rm -rf node_modules and then run npm install (or yarn).
RoliMishra
I had similar issue. In my case it helped to have Yarn installed and first execute the command

yarn


and then execute the command

yarn start


That could work for you too if the project that you cloned have the yarn.lock file. Hope it helps!

Login / Signup to Answer the Question.