Thursday, October 26, 2017

Install Node For Mac


.

How to Install Node and NPM

Installing Node.js and NPM is pretty straightforward using Homebrew. Homebrew handles downloading, unpacking and installing Node and NPM on your system. The whole process (after you have XCode and Homebrew installed) should only take you a few minutes.

Open the Terminal app and type...

 brew install node

Sit back and wait. Homebrew downloads some files and installs them. And that’s it.

To make sure you have Node and NPM installed, run two simple commands to see what version of each is installed:

To see if Node is installed, type node -v in Terminal. This should print the version number so you’ll see something like this v0.10.31.
To see if NPM is installed, type npm -v in Terminal. This should print the version number so you’ll see something like this 1.4.27


How to Update Node and NPM


New versions of Node and NPM come out frequently. You can use Homebrew to update the software it installs.

Make sure Homebrew has the latest version of the Node package. In Terminal type brew update
Upgrade Node: brew upgrade node
How to Uninstall Node and NPM

You can use Homebrew to uninstall packages that it installed: brew uninstall node

With Node.js and NPM installed you’ll soon be able to take advantage of the huge world of NPM modules that can help with a wide variety of tasks both on the web server and on your desktop (or laptop) machine. The NPM site lists all of the official Node packages making it easy to make the choice.

Reference:

https://blog.teamtreehouse.com/install-node-js-npm-mac.

1 comment:

  1. BlueHost is ultimately one of the best web-hosting company with plans for any hosting needs.

    ReplyDelete