If you do not get an object that includes the latest version of npm at 6.14.5,, then you can update npm manually by running the following command: To check what npm version you have, run npm version. You should have npm automatically installed at this point. Simply type nodejs -v into your terminal and it should return v14.4.0. Once we're done, we can check that we have the latest version of Node installed. Once we're done setting up Nodesource, we can now install Nodejs v14.4. You may be prompted to enter the password for your root user. To install the latest version of Node with LTS, change 14 in the command above to 12. NB that v14.4.0 is the latest version of Node but doesn't currently have LTS - long term support provided for it. Run the command below to tell Ubuntu that we want to install the Nodejs Sometimes, you may be collaborating on a project with someone using a different version of node and you need to switch node versions to what the project requires. I like nvm because it allows me use different node versions for different projects. I'll show you how to use both.Īll commands here will be run using the Ubuntu CLI/terminal. To get the latest versions, we can use either nodesource or nvm (node version manager). In this tutorial, what we want to do is get either v12.18.1 (LTS - with Long term support) or v14.4 of Node. As a result, to get the latest versions of any software, we may have to use private packages published by developers. This is because when new versions of a software are released, it can take months for the Ubuntu team to test and release in the official Ubuntu store. This is the latest version in the ubuntu app store, but it's not the latest released version of NodeJS. If you try installing the latest version of node using the apt-package manager, you'll end up with v10.19.0.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |