Home > OS >  how can I fix this error when writing npm run start in vs code terminal?
how can I fix this error when writing npm run start in vs code terminal?

Time:11-28

I want to start using react , so I first installed node in my windows via command prompt , and then installed react using npx create-react-app ... , and later in vs code terminal when I write npm run start I get the following error, I searched a lot but didnt find a way.

npm ERR! code ENOENT
npm ERR! syscall open
npm ERR! path C:\Users\LENOVO\Desktop\React/package.json
npm ERR! errno -4058
npm ERR! enoent ENOENT: no such file or directory, open 'C:\Users\LENOVO\Desktop\React\package.json'
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\LENOVO\AppData\Local\npm-cache\_logs\2021-11-27T19_22_54_184Z-debug.log

CodePudding user response:

First move into the Desktop/React/ Folder then do :npm start

CodePudding user response:

After creating react project a new folder named your project is created. You first to go there using cd /folder name. Then do npm start.

  • Related