Node.js is primarily used for non-blocking, event-driven servers due to its single-threaded nature. It is used for traditional web sites and back-end API services but was designed with real-time, push-based architectures in mind.
NPM is the world’s largest software registry. Open source developers from every continent use NPM to share and borrow packages and additionally, many organizations use NPM to manage private development too.
To use Node.JS and NPM, you need to use a suitable command-line tool like the Windows Command Prompt (CMD), PowerShell or the GIT Bash Command-Line Tool.
Symphony recommends downloading and installing the GIT application, as this contains the relevant tools, such as GIT BASH, that can be used for other projects or scenarios. The GIT application can be downloaded here.
Once installed, search for the GIT BASH application from the Start Menu and ensure this is the command-line tool used going forward.
Note: Other command-line tools can be used as long as the relevant commands are functioning.
Install Node.JS and NPM by following the steps below:
1. Download the Windows installer from the Nodes.js web site here.
Note: Symphony recommends downloading the LTS version as these are the most stable build versions available.
2. Run the downloaded MSI installer.
3. Follow the prompts in the installer (Figure 1):
Figure 1 Node.js Setup
4. Restart your machine for the changes to take effect.
To verify installation, open the GIT Bash Command-Line Tool (or your preferred command-line tool) and enter node -v followed by npm -v (Figure 2):
Figure 2 Commands
The commands will display the Node.JS and NPM versions installed on your system, verifying the installation was successful.