A simple React.js on Windows Setup
Here we will see how to install React.js on Windows setup.
1. Install Node.js and NPM on Windows
In order to install Node.js for Windows, you need to head over to the Node.js website and download the Windows version which is recommended for most users. Afterward, you should install it. NPM comes automatically with Node.js. You’ll need to have Node >= 6 and npm >= 5.2 on your machine.
Now, you should check whether the Node.js installation for Windows was successful with below commands from command prompt.
For Node Version
For NPM version
2. NPM on the Command Line for create-react-app
2.1 Open CMD from your windows and go to your desired location and than run this command
npm install -g create-react-app
And once it’s successfully done unt this command.
npm create-react-app react-app
here you can keep any name instead of ‘react-app’
2.2 Now go into the newly created folder with the command prompt
2.3 Now Start the development server
Now you will see your React application on your browser at “http://localhost:3000/”.