Installing Node.js on CentOS 8
"Node.js is an open-source, cross-platform, JavaScript runtime environment that executes JavaScript code outside a web browser."-Wikipedia. Node.js can be considered the Javascript alternative to PHP. It is popularly used in modern server stacks like in Uber and Netflix servers.
Install Node.js using NodeSource
There are alternatives out there, but we feel this is route is recommended.
This command will download Node.js v12.x. If you want a different version, check this GitHub page for a different Node.js source related to CentOS 8. Replace the link in the command with your new link.
curl -sL https://rpm.nodesource.com/setup_12.x | bash -
To install the the version you downloaded, run the command:
yum install -y nodejs
Node.js should then be installed. Easy right? To test that the Node.js CLI is available, check the version with the command:
node -v
It should then output your expected Node.js version