Sunday, May 19, 2024
HomeCentosHow to Install React on CentOS 8

How to Install React on CentOS 8

React is an open-source, front end, JavaScript library used for building user interfaces or UI components. It is maintained by Facebook and community of individual developers. React can be used as a base in the development of single-page or mobile applications. In this article you will learn how to install react on CentOS 8

Install NodeJs Repository

curl -fsSL | bash -

Install Necessary Development Tools

we must install build tools using below command to compile and install native add-ons from npm.

dnf install gcc-c++ make -y

Install NodeJS

Run following command to install NodeJS.

dnf install nodejs -y

Now verify NodeJS and NPM installation.

node -v
npm -v

Install ReactJS package

npm install -g create-react-app

Starting react app

create-react-app osgroveapp

now switch to the project directory

cd osgroveapp

Finally, run react app using the below command.

npm start

once you execute the below command you will see the similar page on your web browser.

react app

Now you can make changes to app files under “src” directory then reload your react app and you will see new changes on your browser page.

Finally, you learned how to install react on CentOS 8.



Please enter your comment!
Please enter your name here

Most Popular