At first, Do you want to hear something about Node JS.?
Also read: Set up Apache web hosts on Ubuntu 18.04
Yes, Of course
So, What is Node.js?
- Node.js is open source server environment.
- Also, Node.js is free.
- It supports multiple platforms such as windows, mac, ubuntu e.t.c
And Why Node.js is essential?
Node.js uses asynchronous programming
A common task of a web server is to open a file and return the content to the client.
Here is how PHP or ASP handles a file request:
Sends the commands to the computer’s file system.
Waits while the file system opens and reads the file.
Returns the content to the client.
Ready to handle the next request.
Gotcha… Now we are gonna start the installation.
- Node is not a program that you directly launch like other programs.
- To use the Node you must type command-line instructions.
Installing Node and NPM is straightforward, the installer package is available from the Node.js® website. (for mac & Windows)
- CLICK HERE TO START DOWNLOAD (Node 10.13.0 for windows)
- CLICK HERE TO START DOWNLOAD (Node 10.13.0 macOS Installer)
- CLICK HERE TO START DOWNLOAD (Node 10.13.0 Linux Binaries)
- Run the installer (the .msi file you downloaded in the previous step.)
- Follow the prompts in the installer, Accept the license agreement, click the NEXT button a bunch of times and accept the default installation settings.
- Now, Restart your computer
Hurraaaayyyy !!!!! We just now completed the basic installation.
Make sure you have Node and NPM installed by running simple commands. Also to see what version of each is installed.
- TEST NODE
To see if Node is installed, open the Command Prompt or the terminal and type
It will print the version number something like this v8.9.4
- TEST NPM
To see if npm is installed type
npm -v on your terminal or cmd. If installed it will display the version code.
Uninstalling Node and NPM
You can uninstall Node.js and NPM the same as you would uninstall other programs.
So thats it. We just done installation.
In the upcoming tutorials we are going to learn how to start our development server with node js. Coming Soon.