Part 1 : Creating a Web Server
⭐ What is a Web Server ?
A Web Server is basically a system that accepts requests from the client and sends back responses.
We have built a simple web server using
http module in Node.js.
http is a built-in module in Node.js. It provides us with all the networking capabilities, such as creating a HTTP server. It allows Node.js to transfer data over the HTTP(Hypertext Transfer protocol).
🚀 Get Started
Clone or download the repository.
Once you've downloaded the repo, Open it in an editor of your choice.
Open the terminal and traverse to part_1 directory.
Now run command
node index.jsto start the server.
Open your browser and go to
127.0.0.1:8000to see your server running.
📝 Learn More
To Learn more about creating a web server, you may refer this article.