SlideShare ist ein Scribd-Unternehmen logo
1 von 10
Objective
What is Node JS?
Why Node JS?
Setup NodeJS
Node Package Manager
Hello World Application
What is Node.js?
 Created by Ryan Dahl in 2009 in Joyent
 Server-side JavaScript Framework
 Uses V8 is an open source JavaScript engine developed
by Google. Its written in C++ and is used in Google
Chrome Browser
 Event-driven with Non-blocking I/O
 Single threaded
Why Node.js?
1. Free from deadlocking Process
2. Event Driven Programming
3. Nonblocking I/O
4. Easy to build the scalable application
5. Same language(JS) for both backend and frontend
6. Large open source package System(NPM)
7. Hosting
8. A big corporate is taking care of project(Joyent)
9. Easy to build real-time application
Blocking Vs NonBlocking
Node JS Installation
Node JS installation can be done in four ways.
First of all, Go to the Node JS website which is
https://nodejs.org/en/download.
1. Precompiled Binary
2. Installer
3. Source Code
4. NVM (Node Version Manager)
Installation using NVM
NodeJS Installation command using the NVM:
NVM install <version_number>
This command will check the stable version based on the version
number and install the stable version.
Node JS basic commands
To check the version of install NodeJS
node -v
To change the NodeJS version
NVM use <version_number>
To run JavaScript code right from your terminal, you can use
the – e option
node -e 'console.log(3 + 2)'
Or
node -p '3 + 2'
NPM
NPM is a package manager for Node JS.NPM is the pre-build
libraries for Node JS.
Whenever you install Node JS, npm will automatically install in
your system.
NPM.inc is the company that host and maintains it.It is available
at https://npmjs.com.
To get the npm version, following command is used:
npm - v
Node.JS – as an interactive shell
> node
3 + 4
7
> true != false
true
Node.JS – as an interactive shell
> node
3 + 4
7
> true != false
true

Weitere ähnliche Inhalte

Was ist angesagt?

Was ist angesagt? (20)

What is Node.js | Node.js Tutorial for Beginners | Node.js Modules | Node.js ...
What is Node.js | Node.js Tutorial for Beginners | Node.js Modules | Node.js ...What is Node.js | Node.js Tutorial for Beginners | Node.js Modules | Node.js ...
What is Node.js | Node.js Tutorial for Beginners | Node.js Modules | Node.js ...
 
NodeJS guide for beginners
NodeJS guide for beginnersNodeJS guide for beginners
NodeJS guide for beginners
 
Introduction to Node.js
Introduction to Node.jsIntroduction to Node.js
Introduction to Node.js
 
Fundamental of Node.JS - Internship Presentation - Week7
Fundamental of Node.JS - Internship Presentation - Week7Fundamental of Node.JS - Internship Presentation - Week7
Fundamental of Node.JS - Internship Presentation - Week7
 
Introduction to Node.js
Introduction to Node.jsIntroduction to Node.js
Introduction to Node.js
 
Introduction to Node.js
Introduction to Node.jsIntroduction to Node.js
Introduction to Node.js
 
Node.js Tutorial for Beginners | Node.js Web Application Tutorial | Node.js T...
Node.js Tutorial for Beginners | Node.js Web Application Tutorial | Node.js T...Node.js Tutorial for Beginners | Node.js Web Application Tutorial | Node.js T...
Node.js Tutorial for Beginners | Node.js Web Application Tutorial | Node.js T...
 
Node js Introduction
Node js IntroductionNode js Introduction
Node js Introduction
 
Nodejs vatsal shah
Nodejs vatsal shahNodejs vatsal shah
Nodejs vatsal shah
 
Node.js Express
Node.js  ExpressNode.js  Express
Node.js Express
 
Rest api with node js and express
Rest api with node js and expressRest api with node js and express
Rest api with node js and express
 
NodeJS - Server Side JS
NodeJS - Server Side JS NodeJS - Server Side JS
NodeJS - Server Side JS
 
Build RESTful API Using Express JS
Build RESTful API Using Express JSBuild RESTful API Using Express JS
Build RESTful API Using Express JS
 
Node js
Node jsNode js
Node js
 
Nodejs functions & modules
Nodejs functions & modulesNodejs functions & modules
Nodejs functions & modules
 
Introduction to NodeJS
Introduction to NodeJSIntroduction to NodeJS
Introduction to NodeJS
 
Node JS Crash Course
Node JS Crash CourseNode JS Crash Course
Node JS Crash Course
 
Express js
Express jsExpress js
Express js
 
ReactJS presentation.pptx
ReactJS presentation.pptxReactJS presentation.pptx
ReactJS presentation.pptx
 
Introduction to MERN Stack
Introduction to MERN StackIntroduction to MERN Stack
Introduction to MERN Stack
 

Ähnlich wie Node.js Basics

Node.js.pdf
Node.js.pdfNode.js.pdf
Node.js.pdf
gulfam ali
 
Develop android application with mono for android
Develop android application with mono for androidDevelop android application with mono for android
Develop android application with mono for android
Nicko Satria Consulting
 

Ähnlich wie Node.js Basics (20)

3 Things Everyone Knows About Node JS That You Don't
3 Things Everyone Knows About Node JS That You Don't3 Things Everyone Knows About Node JS That You Don't
3 Things Everyone Knows About Node JS That You Don't
 
Node js presentation
Node js presentationNode js presentation
Node js presentation
 
02 Node introduction
02 Node introduction02 Node introduction
02 Node introduction
 
Node.js.pdf
Node.js.pdfNode.js.pdf
Node.js.pdf
 
All You Need to Know About Using Node.pdf
All You Need to Know About Using Node.pdfAll You Need to Know About Using Node.pdf
All You Need to Know About Using Node.pdf
 
Node js for beginners
Node js for beginnersNode js for beginners
Node js for beginners
 
Node js (runtime environment + js library) platform
Node js (runtime environment + js library) platformNode js (runtime environment + js library) platform
Node js (runtime environment + js library) platform
 
Node J pdf.docx
Node J pdf.docxNode J pdf.docx
Node J pdf.docx
 
Node J pdf.docx
Node J pdf.docxNode J pdf.docx
Node J pdf.docx
 
How open source cross platform as node.js 14 develop runtime applications
How open source cross platform as node.js 14 develop runtime applications How open source cross platform as node.js 14 develop runtime applications
How open source cross platform as node.js 14 develop runtime applications
 
Develop android application with mono for android
Develop android application with mono for androidDevelop android application with mono for android
Develop android application with mono for android
 
NCDevCon 2017 - Cross Platform Mobile Apps
NCDevCon 2017 - Cross Platform Mobile AppsNCDevCon 2017 - Cross Platform Mobile Apps
NCDevCon 2017 - Cross Platform Mobile Apps
 
Node, express & sails
Node, express & sailsNode, express & sails
Node, express & sails
 
Node js first look - 2016
Node js first look - 2016Node js first look - 2016
Node js first look - 2016
 
Introduction to React Native
Introduction to React NativeIntroduction to React Native
Introduction to React Native
 
Nodejs
NodejsNodejs
Nodejs
 
Node.js tutoria for beginner
Node.js tutoria for beginnerNode.js tutoria for beginner
Node.js tutoria for beginner
 
Nodejs
NodejsNodejs
Nodejs
 
Complete MVC on NodeJS
Complete MVC on NodeJSComplete MVC on NodeJS
Complete MVC on NodeJS
 
An Introduction to Node.js Development with Windows Azure
An Introduction to Node.js Development with Windows AzureAn Introduction to Node.js Development with Windows Azure
An Introduction to Node.js Development with Windows Azure
 

Mehr von TheCreativedev Blog

Mehr von TheCreativedev Blog (9)

Node.js Express Framework
Node.js Express FrameworkNode.js Express Framework
Node.js Express Framework
 
Node js Modules and Event Emitters
Node js Modules and Event EmittersNode js Modules and Event Emitters
Node js Modules and Event Emitters
 
PHP - DataType,Variable,Constant,Operators,Array,Include and require
PHP - DataType,Variable,Constant,Operators,Array,Include and requirePHP - DataType,Variable,Constant,Operators,Array,Include and require
PHP - DataType,Variable,Constant,Operators,Array,Include and require
 
Introduction to PHP Basics
Introduction to PHP BasicsIntroduction to PHP Basics
Introduction to PHP Basics
 
Canvas in html5
Canvas in html5Canvas in html5
Canvas in html5
 
Network Security Through FIREWALL
Network Security Through FIREWALLNetwork Security Through FIREWALL
Network Security Through FIREWALL
 
Post via e mail in word press
Post via e mail in word pressPost via e mail in word press
Post via e mail in word press
 
Post via e mail in WordPress
Post via e mail in WordPressPost via e mail in WordPress
Post via e mail in WordPress
 
TO ADD NEW URL REWRITE RULE IN WORDPRESS
TO ADD NEW URL REWRITE RULE IN WORDPRESSTO ADD NEW URL REWRITE RULE IN WORDPRESS
TO ADD NEW URL REWRITE RULE IN WORDPRESS
 

Kürzlich hochgeladen

Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Safe Software
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
?#DUbAI#??##{{(☎️+971_581248768%)**%*]'#abortion pills for sale in dubai@
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Victor Rentea
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
panagenda
 

Kürzlich hochgeladen (20)

How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Artificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : UncertaintyArtificial Intelligence Chap.5 : Uncertainty
Artificial Intelligence Chap.5 : Uncertainty
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Vector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptxVector Search -An Introduction in Oracle Database 23ai.pptx
Vector Search -An Introduction in Oracle Database 23ai.pptx
 
CNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In PakistanCNIC Information System with Pakdata Cf In Pakistan
CNIC Information System with Pakdata Cf In Pakistan
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital Adaptability
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering Developers
 

Node.js Basics

  • 1. Objective What is Node JS? Why Node JS? Setup NodeJS Node Package Manager Hello World Application
  • 2. What is Node.js?  Created by Ryan Dahl in 2009 in Joyent  Server-side JavaScript Framework  Uses V8 is an open source JavaScript engine developed by Google. Its written in C++ and is used in Google Chrome Browser  Event-driven with Non-blocking I/O  Single threaded
  • 3. Why Node.js? 1. Free from deadlocking Process 2. Event Driven Programming 3. Nonblocking I/O 4. Easy to build the scalable application 5. Same language(JS) for both backend and frontend 6. Large open source package System(NPM) 7. Hosting 8. A big corporate is taking care of project(Joyent) 9. Easy to build real-time application
  • 5. Node JS Installation Node JS installation can be done in four ways. First of all, Go to the Node JS website which is https://nodejs.org/en/download. 1. Precompiled Binary 2. Installer 3. Source Code 4. NVM (Node Version Manager)
  • 6. Installation using NVM NodeJS Installation command using the NVM: NVM install <version_number> This command will check the stable version based on the version number and install the stable version.
  • 7. Node JS basic commands To check the version of install NodeJS node -v To change the NodeJS version NVM use <version_number> To run JavaScript code right from your terminal, you can use the – e option node -e 'console.log(3 + 2)' Or node -p '3 + 2'
  • 8. NPM NPM is a package manager for Node JS.NPM is the pre-build libraries for Node JS. Whenever you install Node JS, npm will automatically install in your system. NPM.inc is the company that host and maintains it.It is available at https://npmjs.com. To get the npm version, following command is used: npm - v
  • 9. Node.JS – as an interactive shell > node 3 + 4 7 > true != false true
  • 10. Node.JS – as an interactive shell > node 3 + 4 7 > true != false true