Creating frontend and web-based applications
node.js is one of the most popular choices. In order to install
node.js we need to decide about the version that we want to install. There are a couple of versions available
- 12.x (LTS)
For this project, we will use version
node.js. To start the installation we need to add the repository key and the repository URL to the system. All these steps are handled by
node.js’s official script.
curl -sL https://deb.nodesource.com/setup_12.x | sudo -E bash -
This will download the initialization script and add the required package info to the system. If asked for a password please provide
Now, to install
node.js 12.x run the following command
sudo apt-get install -y nodejs
This will install
npm (node package manager). Verify the installation with
If everything were okay and
node.js has been installed correctly, the output should be similar as below (although the version may differ).