![]() We proceed to verify the installed version. With the command above we also install the npm. We will install the latest stable version:We will install the latest stable version: nvm install 10.15.3ġ0.- Installing the lastest version of node.js Now we can install different versions of node.js nvm ls-remote Now to use nvm we must do: source ~/.profile curl -o- | bashĪt the end of the installation, you will create a hidden nvm folder. Using NVM we can have more flexibility to install node.js because we can choose which version to install from a quick and easy way.įirst we can check on your github page that we can download NVM in two ways, using wget or curl. In addition we install a higher version of node.js 3.- Installing node.js using NVM With this method, there is no need to install npm separately. Then we proceed to install it: sudo apt install nodejsĪnd finally we check the installed version. In this case we chose version 10.x because it is a higher version than the official repositories, but you can check the rest of the versions supported by the PPA here If you have installed node.js before, you must uninstall it.įirst we must add the repository in question. Recent versions of node.js provide us with security updates as well as more improvements than ever before. For this we write: sudo apt install npmįinally we can consult the installed version of node.js nodejs -vĤ.- checking the installed version 2.- Using PPAįor more recent versions of node.js we usually use this installation method. However, in many cases you need your NPM package manager which is not installed by default with this method. Next we proceed to install node.js from the official repositories with: sudo apt install nodejs Then we proceed to update the system in order to have the latest security patches. This is because over time the installed version could be considered obsolete.įirst we must open a terminal. ![]() This method is safer, more stable and easier but does not provide the flexibility that many would like. 1.- Using the official Ubuntu repositories The options are 3: use the official repositories o ubuntu, use the external PPA or install it via NVM. The choice will depend on your level of knowledge and what you really want for your computer.
0 Comments
Leave a Reply. |