Install NodeJs Repository
curl -fsSL https://rpm.nodesource.com/setup_current.x | 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
Run following command to install NodeJS.
dnf install nodejs -y
Now verify NodeJS and NPM installation.
Install ReactJS package
npm install -g create-react-app
Starting react app
now switch to the project directory
Finally, run react app using the below command.
once you execute the below command you will see the similar page on your web browser.
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.