Install Reactjs - Step by Step Installation Guide (GitHub)
Reactjs can be installed on your local machine by using following ways:
npx create-react-app my-first-project
npm init react-app my-first-project
yarn create react-app my-first-project
After installing reactjs using any of the above method
Go to the your project folder and run your react app
cd my-first-project npm start
Note: my-first-project is the name of your react project, you can change it as per your interest/requirement.
Step-1: First, install - Create React App.
npm install -g create-react-app
sudo npm install -g create-react-app
Step-2: Now, create your project.
Step-3: Now, start the your app/project.
//Go to your project folder cd my-first-project //Start your App npm start
- package.json - it's a json config file which contains the metadata details (e.g.- package name and thier versions, dependencies, devdependencies, etc.) of your react app.
- package-lock.json - it's contains actual link of installed modules/dependencies in your react js application.
- src - it's your main folder which contains all your code & components.
- public - It's root folder of your react js application (index.html).
- node_modules - It's Node Modules Library created by Node Package Manager (NPM).