Codxplore.com

Latest news:

Sahih al-Bukhari (সহীহ বুখারী) is a free Hadith application for android. This application is advertisement free. Download now https://play.google.com/store/apps/details?id=com.akramhossin.bukharisharif

Install Node.js on Ubuntu 20.04


Install Node.js on Ubuntu 20.04

Initiation 

Node.js is an open-source, cross-platform, back-end JavaScript runtime environment 

that runs on the V8 engine and executes javaScript code outside a web browser

Prerequisites for installing Node.js

If you are using Ubuntu 20.04. Before we start, we should have an user account with sudo privileges set up on the system.

We will learn how to do this by following these steps for Ubuntu 20.04 version

Installing Node.js stable version

In ubuntu 20.04 has a version of Node.js in there default repositories which can be used to provide us

consistent user experience across the multiple platform.

To get install that version, we can use apt package manager. Firstly we need to refresh our local package index by entering:

sudo apt update into the terminal

To install Node.js from the repositories type

sudo apt install nodejs

If the package exists in the repositories, this is what we need to do to set up with Node.js. 

In many cases, we also want to install npm package which is Node.js package manager. We can do this by typing:

sudo apt install npm in the terminal

This terminal command will allow us to install node modules and packages to use.

Because of a conflict with another package name as node the executable from the ubuntu repositories is called Node.js instead of node.

We have to keep this in mind as we are running command in the terminal.

To check installed version of Node.js after these steps type:

nodejs -v in the terminal

once we see the version number of Node.js we have successfully installed Node.js from the ubuntu repositories.


Views : 503

Subscribe Us


Follow Us