Skip to content

Latest commit

 

History

History
14 lines (9 loc) · 1.02 KB

File metadata and controls

14 lines (9 loc) · 1.02 KB

Node.js

It is a javascript runtime environment by which we can execute javascript code on server and it can be used to build webserver command line interface and web application backend.

Node is build on javascript Chrome V8 engine. node will compile over javascript code to machine readable format. It is build using C++. Node does not know how to run javascript code. It passed the js code to V8 engine and get the result back.

  • In browser we have "window" object but if you will check, this is not available in node. Node provide similar kind of thing that is known as "global" variable.It expose lot of properties and method to us.
  • similarly In browser we have "document" but this is not avaialbe in node. We have "Process" in node. It has various properties and methods to manipulate node. for example we can use "process.exit()" to exit the node window.
  • It uses an event driven non blocking I/O model that makes it light weight and efficient.
  • In 2023 the latest version of node is 20.X