Why is Node.js becoming so popular?

Why is Node.js becoming so popular?

To put it simple, Node.js outshines other web applications by replacing websockets with revolutionary push technology. You would ask, what is so unique about it? Well, we finally have cutting-edge web applications with two-way, real-time connections where both the server and client can build communication, allowing them to exchange valuable data. Now this is in stark contrast to our conventional web response paradigm where only the client initiates communication.

Node.js is a server technology used to build and run web applications, similar to what ASP.NET, Ruby on Rails or Spring Framework does. It uses JavaScript as its main language, a built-in lightweight web server and a whole bunch of plugins managed through the Node Package Manager (NPM) that allows you to mold your application to your needs, like adding Model-View-Controller features, RESTful services, OAuth and SSL security and others.

The knowledge that systems written in Node.js will continue to get extremely fast. Google is investing heavily in the V8 Javascript implementation. This means that anyone who writes code in node will find their software running faster over time by virtue of constant upstream improvements.

Moreover, once you've begun to do work with node.js, you realise that there are a few cognitive hurdles to overcome. There is far less mental switching between the front and the back end of a web project.

I also believe that the project's simple focus, writing network servers for I/O bound work, meant that it could do that very well. The community doesn't need to worry about GUI programming, dealing with matrix multiplication or anything else. 

The library support is also very clean. Everything that has been built to support Node.js works with other components very well. One of the problems with working with Twisted is that many of the Python libraries can't because because they block on I/O.

But, really, why has it become so popular all of a sudden? Sounds like yet another web technology like any other else, right?

Well, in a nutshell:

  • Language re-use  Technologies like ASP.NET or Spring requires developers to know yet another language to write code on the server-side; be it C#, VB.NET, Java or any other. On the other hand, Node.js uses JavaScript both on the server and client side, meaning that developers only have to talk in a single language across all layers.
  • Easy developer transition  JavaScript is a common ground between web developers, that’s a known fact. Most of us know JavaScript or have used it at some point in time; of course, because of this, transitioning a web developer from any other web technology to Node.js is easy as pie.
  • It is lightweight  Node.js uses an event-driven architecture which means everything done on it, every single call and operation, is a chain of asynchronous callbacks. This allows Node.js to run on a single thread, different to other web technologies, which spawn a new thread per-client request. This is the very foundation of the non-blocking I/O nature you may have heard that is Node.js’ main feature.
  • Built-in support for object databases   It is really common for Node.js applications to use object databases such as MongoDB. MongoDB, contrary to traditional SQL databases, it uses a document-based model instead of a relational model; this means that instead of tables, it uses objects resembling JSON. Just the right answer for ORM fans.
  • Wide support from IDEs and code editors  JavaScript has been around for a long time, so code hinting and highlighting is featured by a bunch IDEs like Visual Studio and Eclipse; also editors like Notepad++ and Sublime Text.
  • Can be hosted almost anywhere   Several web servers and cloud-based hosting providers support hosting of Node.js web applications out-of-the-box. To mention a couple: Google, Microsoft IIS, Heroku, Microsoft Azure, Amazon (AWS), and a bunch others.


要查看或添加评论,请登录

Yogendra Kapoor的更多文章

社区洞察

其他会员也浏览了