Learning About Node.js For Beginners

Shehani Fernando
3 min readMar 19, 2021

What is Node.js?

Node.js is an open-source and cross-platform JavaScript runtime environment. It is a popular tool for almost any kind of project!

It runs on various platforms (Windows, Linux, Unix, Mac OS X, etc.). It is used to develop I/O intensive web applications like video streaming sites, single-page applications, and other web applications.

History

  • Ryan Dahl invented Node.js in 2009.

Why Node.js?

Node.js uses asynchronous programming!

Node.js is primarily used for non-blocking, event-driven servers, due to its single-threaded nature. It’s used for traditional web sites and back-end API services, but was designed with real-time, push-based architectures in mind.

Concepts

The following diagram depicts some important parts of Node.js.

Features of Node.js

  1. Asynchronous and Event Driven
  2. Very Fast
  3. Single Threaded but Highly Scalable
  4. No Buffering
  5. License

REFER MORE TO LEARN FURTHER ABOUT NODE.JS!

Node.js tutorial for Beginners

Where to Use Node.js?

Following are the areas where Node.js is proving itself as a perfect technology partner.

  • I/O bound Applications
  • Data Streaming Applications
  • Data Intensive Real-time Applications (DIRT)
  • JSON APIs based Applications
  • Single Page Applications

Where Not to Use Node.js?

It is not advisable to use Node.js for CPU intensive applications.

What Can Node.js Do?

  • Node.js can generate dynamic page content
  • Node.js can create, open, read, write, delete, and close files on the server
  • Node.js can collect form data
  • Node.js can add, delete, modify data in your database

Advantages of Node.js

Advantages of Node.js
  1. Open Source
  2. JavaScript Language
  3. Node.js is fast
  4. Asynchronous I/O
  5. Active community support
  6. Rest API
  7. Caching modules
  8. Less problems with concurrency
  9. Unit Testing
  10. Streaming Data

Disadvantages of Node.js

1. Not effective with large scale applications

2. Inconsistent

3. Not suited for CPU-intensive tasks

4. Poorly supported to relational databases

Conclusion

The Node.js is more advantageous to the developers in comparison to its disadvantages. What’s more important is the fact that it has extended the area of JavaScript application and can be evidently used for both frontend as well as backend servers.

--

--