Score:0

How to install node.js 16.13.1

be flag

I want to use npm but it tells me on every command "npm does not support Node.js v10.19.0" so I want to update my node.js. I performed sudo apt update I tried to install it with sudo apt install nodejs but it tells me the latest version is already installed (but thats not true)

nodejs ist schon die neueste Version (10.19.0~dfsg-3ubuntu1).

Translation: nodejs already is the latest version. I downloaded the latest version 16.13.1 LTS as tar.gz and unpacked the files. I found the commands to use these file are

./configure
make
sudo make install

but where? In the unpacked folder is no folder named cofigure. What am I doing wrong? Thanks for your help and time

Score:0
ht flag

The version of most applications available via apt in the LTS Ubuntu distribution repositories are usually not the latest. The reasons for this are answered in the question Why don't the Ubuntu repositories have the latest versions of software?

If you want the latest, you might be better off installing the snap provided by the OpenJS Foundation, with the command:

sudo snap install node --classic

More details here: https://snapcraft.io/install/node/ubuntu

CrackbuddyMethusalem avatar
be flag
I installed the snap but yet there is no difference. It's still saying "npm does not support Node.js v10.19.0". Do I need to use special commands to call the snap version?
ht flag
Rather than using the snap, you might be better off adding the node repository and installing from there. To remove the snap use the following command: sudo snap remove node Then follow the instructions here: https://askubuntu.com/questions/594656/how-to-install-the-latest-versions-of-nodejs-and-npm
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.