How to create a React App in current directory

How to create a React App in current directory

Posted by Ervin Adams on May 28, 2021

In this tutorial you will be shown how to create a React.js project with create-react-app

Step 1. Install Node.js

Go here and install Node.js.

Step 2. check Node.js was installed properly by executing command

node -v

Step 3. Go to your C drive create a folder for react projects, call the folder whatever you would like. Then execute command within that folder from command prompt.

npx create-react-app my-app

Step 4. once the app is created, execute command

cd my-app

Step 5. Within the project execute command

npm start

The project should automatically launch within a web browser. If that is not the case and the app is running, go the http://localhost:3000.

In order to stop the project, execute command ctrl c.