Home > Software design >  How to install react on an existing react project using VSC but with a fresh OS installed?
How to install react on an existing react project using VSC but with a fresh OS installed?

Time:10-14

When I started the project a while back from scratch all packaged installed successfully worked on the project for a while I used:

npm create-react-app my-app

I re-installed my OS which is Windows 10 now. How can I start the same project again with out over-writing or changing anything from my project?

I tried

npm start

and

npm install --save-dev react-scripts

got the same error back : npm : The term 'npm' is not recognized as the name of a cmdlet, function, script file, or operable program.

CodePudding user response:

I hope you first install node.js(npm package) & also JDK on your new OS. After that install react-native-cli globally. npm install -g react-native-cli .

After successful installation, you can create your new app. npx react-native init SampleApp.

CodePudding user response:

I found a solution:

First I installed Node manually from the windows installer https://nodejs.org/en/download/

Then I ran:

npm install react

in the VSC terminal.

It took a little longer than usual for it to load up the page, but it did eventually. I'm not quite sure if there are any bugs my way, but at least got it to start. I will edit the answer, if possible, with updates if there is any problem that shows up. If you do this, make sure to....

  • Related