Node.js Application Without Any Framework

It sounds typical node.js without any framework, but it’s true and you came to the right place to know how to deal node.js without using any framework i.e. Express, Koa, Hapi etc.

In previous article, we have done our HTTP server setup using node.js. Let’s have a quick view our last code:

In this case, on each and every url, you found “welcome to node.js world”. Now we will send different response, according to requested url.

Now, run this application using node <filename> i.e node index.js. Here, we track requested url and respectively show that conetnt on that url, and handle 404 condition in all other cases. We will use framework for full blown web application. In next article, will cover “Node.js with Express”.

You can ask any query about article and you can share this with everyone in the comments section below.

Oh, and if you liked this, click the 💚 below. Follow me for more articles on technology.

Thanks!
Happy Coding!!