Hey reader👋Hope you are doing well😊
In the last post we have discussed about Introduction to NodeJS. In this post we are going to see how to use NodeJS.
So let's get started🔥
Installation
The official Node.js website has installation instructions for Node.js: [https://nodejs.org].
Get Started
Once you have downloaded the NodeJS. Let's check the version of NodeJS.
Step 1-> Open VS Code
Step 2-> Open Terminal
Step 3-> Type command
node -v
in terminal to check node version
You will get the version of NodeJS.
Now let's print Hello World using NodeJS-:
Step 1-> Create script.js file.
Step 2-> Write code.
Don't go into technicalities of code right now. Just understand that here we have created a server that can be accessed on port 8080 and whenever any user tries to access your computer on port 8080 a "Hello World" statement is printed.
It was this simple😉
Instead of using VSCode you can use CLI or Node CLI too.
So this is how you can get started with NodeJS. In the next blog we are going to talk about Modules in NodeJS.
Thankyou🤍
Top comments (0)