Node js Environment set up

Download Node js from below Link and Install it.

https://nodejs.org/en/

Setting environment variable for node js


 

Checking node version


 

Simple Program

Create simple app.js file


Running app.js file(Navigate to path where you saved app.js) and run below command


 

Node Js Introduction

Node.js is an event-based, non-blocking, asynchronous I/O framework that uses Google’s V8 JavaScript engine And library.Node.js is an open source server framework.
It is used for developing applications that make heavy use of the ability to run JavaScript both on the client, as well as on server side and therefore benefit from the re-usability of code and the lack of context switching.

Where to Use


• Web Application frameworks
• Messaging middleware
• Servers for HTML5 multi-player games, or streaming audio/video
• Real time applications
• Cross-platform programs
• I/O intensive web applications
• Video streaming sites,
• Single-page applications
You can/should use Node.js for a number of reasons:


  •  It’s a low-level, lightweight and standalone framework which brings power of JavaScript to the server-side
    environment.
  • If you like higher level abstraction then there is a large number of modules and the npm package manager where you can find wide range of ready-to-use applications.
  • Fast/unencumbered development process – for example, you don’t need tons of additional tools in order to start
    writing serious stuff.
  •  Big open source based community full of enthusiasts and very talented people. Made for creating real-time web oriented applications – that’s where the (near) future is.

Node js Feature


  • Node.js is an event-based, non-blocking, asynchronous I/O framework that uses Google’s V8 JavaScript engine and
    library.
  • A notable feature of node.js is that it is non-blocking – if one task stalls or pauses for an IO operation, another
    can take over while it is idle.
  • This allows for high efficiency as the program as a whole never has to idle and wait
    for one task to finish. Libraries such as a sync take Advantage of this capability.

 

Link to Refer:

https://nodejs.org/en/