Create Web Server in Node JS | Use HTTP Module in Node.js

Опубликовано: 30 Сентябрь 2024
на канале: Stubborn Developers
332
14

#stubborndevelopers

In this video we will learn that how we can create a Node.js web server to handle HTTP requests and return response back to client.

To access web pages of any web application, we need a web server. The web server will handle all the http requests for the web application like: IIS is a web server for ASP.NET web applications and Apache is a web server for PHP or Java web applications.

Node.js provides capabilities to create your own web server using ‘http’ module which will handle HTTP requests asynchronously on a particular port. You can use IIS or Apache to run Node.js web application but it is recommended to use Node.js web server.

//Require http module
const http = require("http");

// Create Server
http.createServer()

*********** Node.JS Tutorial in English 2021 Playlist ***********
   • how to install node js  

*********** React.JS Tutorial in Hindi 2021 Playlist ***********
   • react js introduction in hindi