The Wayback Machine - https://web.archive.org/web/20240812192654/https://www.geeksforgeeks.org/why-node-js/
Open In App

Why Node.js ?

Last Updated : 12 Mar, 2019
Comments
Improve
Suggest changes
Like Article
Like
Save
Share
Report
News Follow

Node.js is an open source, a server-side script which runs on the top of Google’s open-source scripting engine V8. Node.js is fast, lightweight and efficient. It uses the asynchronous mode of operation, event-driven Input/Output rather than using the traditional threads or separate threads for each process. Node.js was originally written by Ryan Dahl in the year 2009. It is a cross-platform Javascript run-time environment that executes Javascript code outside of a browser. Node.js uses javascript for creating node applications or we can use any other language that ultimately compiles to javascript (like typescript). The javascript is written in the same way as we’d use in any client-side application. However, we need to set up the node development environment.

Node.js is the greatest tool for building real-time web applications. It provides cross-platform applications which run easily on any web. So you basically don’t need anything extra for running up a node application. You only need for making one. According to the Node.js Survey of users, 43% of Node.js programmers claim to use Node.js for enterprise apps. It’s a light, scalable and open-source language platform which makes it very easy to build apps even at the enterprise level also. Overall it increases the efficiency of the development process as it fills the gap between frontend and backend applications. It uses the approach of non-blocking I/O. In Non-blocking I/O approach, you can initiate a request in parallel for user2 without waiting for the response to the request for user1. The requests in Node.js can initiate in parallel. This non-blocking I/O eliminates the need for multi-threading.

Npm (Node Package Manager)
These are the libraries which are built by the awesome community which will solve almost all the generic problems related to the Node.js. Npm has packages which are used in our apps to make the development process faster and more efficient.

Node Modules
Node.js has a set of built-in modules which can be used without any further installation. We can install some custom modules from the NPM as per the need of the application. We can also create modules of our own and use them by importing it in our apps. Basically, the Node module is a block of code which can be used again in any node.js component without impacting any other node.js component. The modules in node.js work independently without impacting the existence of any other functions.


Previous Article
Next Article

Similar Reads

Why are HTTP cookies used by Node.js for sending and receiving HTTP cookies?
The HTTP protocol is one of the most important protocols of the Application layer of the OSI model. The main use of this protocol is for sending hypertext information to the client to the server and server to the client to communicate on the World Wide Web. But, the HTTP protocol is a stateless protocol which means that this protocol cannot maintai
5 min read
Why Node.js doesn't see files in node_modules folder ?
Sometimes developers want to serve some static asset from node_modules. Usually, we don't want to expose any of your internal paths to the outside world. If your files are in the node_modules directory then you can make a static route in your server that fetches its files from whatever directory you specify. The express.static() function is used to
2 min read
Why to Use Node.js For Backend Development?
JavaScript is the universal language for building web applications. It is used in frontend (client-side) and backend (server-side) development as well. But the truth that the beauty of the front-end relies on the back-end can't be denied. This is when NodeJS comes into the picture. NodeJS is the best choice for server-side application development d
7 min read
Why Node.js is famous over other environments in JavaScript ?
Node.js is a platform that allows developers to build web applications with JavaScript. It is particularly useful for building real-time, high-concurrency applications, such as chat systems, online games, and real-time data processing pipelines. Let me explain to you node.js in a more fun and simpler way: Think of Node.js as a magical microphone at
5 min read
What is LTS releases of Node.js why should you care ?
Node.js is a powerful and popular open-source runtime environment for JavaScript that allows developers to build scalable, high-performance web applications. One of the key features of Node.js is its ability to receive updates and new versions regularly, which can bring new features, improvements, and bug fixes to the platform. However, not all upd
3 min read
Why Node.js is a Single Threaded Language ?
Node.js is a popular runtime environment that allows developers to build scalable network applications using JavaScript. One of the most distinctive features of Node.js is its single-threaded architecture, which often raises questions among new developers about why it was designed this way. This article will delve into the rationale behind Node.js
4 min read
Why we use setTimeout() function in Node.js ?
The purpose of setTimeout function is to execute a piece of code after a certain interval of time. The setTimeout() function accepts two arguments. The first argument is a function and the second argument is time in milliseconds. The setTimeout() executes the function passed in the first argument after the time specified in the second argument. Jav
3 min read
Why do we need C++ Addons in Node.js ?
C++ Addons in Node.js extend its capabilities by allowing native C++ code integration. They improve the performance for intense tasks, providing access to C/C++ libraries, and facilitating low-level system interactions that are not easily to achieve with JavaScript alone. C++ addons in Node.js allow developers to write performance-critical parts of
4 min read
Why Zlib is used in Node.js ?
Zlib is a crucial library in Node.js used for data compression and decompression. It's widely employed in web development and various applications to handle data more efficiently. Understanding Zlib's significance in Node.js can greatly enhance your capability to manage data transmission, storage, and overall application performance. What is Zlib?Z
4 min read
Node.js Automatic restart Node.js server with nodemon
We generally type following command for starting NodeJs server: node server.js In this case, if we make any changes to the project then we will have to restart the server by killing it using CTRL+C and then typing the same command again. node server.js It is a very hectic task for the development process. Nodemon is a package for handling this rest
1 min read
Article Tags :
three90RightbarBannerImg