Setup nodejs

  • 195 views
Uploaded on

Setup Node.js Development Environment and Debugging

Setup Node.js Development Environment and Debugging

More in: Technology , Business
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Be the first to comment
    Be the first to like this
No Downloads

Views

Total Views
195
On Slideshare
0
From Embeds
0
Number of Embeds
0

Actions

Shares
Downloads
1
Comments
0
Likes
0

Embeds 0

No embeds

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
    No notes for slide

Transcript

  • 1. SETUP NODE.JS DEV ENVIRONMENT & DEBUGGING
  • 2. ABOUT Rubyist / JavaScripter Yeoman team member Works at @whatznear Blog at blog.revathskumar.com Twitter/Github - @revathskumar
  • 3. INSTALLATION sd adatrpstr pacrsland.s uo d-p-eoioy p:hi-e/oej sd atgtudt uo p-e pae sd atgtisalndj uo p-e ntl oes
  • 4. NOW, INSTALLING PACKAGES REQUIRES SUDO
  • 5. SET ENV VARIABLE TO AVOID SUDO mdr~.p-akgs ki /nmpcae eh 'rfx~.p-akgs > ~.pr co pei=/nmpcae' > /nmc Add to ~ . s r or ~ . a h c /zhc /bsr NMPCAE=~.p-akgs P_AKGS"/nmpcae" ND_AH"NMPCAE/i/oemdls$OEPT" OEPT=$P_AKGSlbnd_oue:ND_AH PT=$P_AKGSbn$AH /bnpt AH"NMPCAE/i:PT" /i ah
  • 6. NVM : NODE VERSION MANAGER
  • 7. NVM-INSTALL hts/rwgtu.o/rainxnmmse/ntl.h|s tp:/a.ihbcmcetoi/v/atrisals h OR gtcoegt/gtu.o/rainxnmgt~.v i ln i:/ihbcmcetoi/v.i /nm .~.v/v.h /nmnms
  • 8. INSTALLING NODE nmisalv.02 v ntl 01.4
  • 9. USING NVM nmuev.02 v s 01.4 nmaisdfutv.02 v la eal 01.4 nmuisalv.02 v nntl 01.4 nmrnv.02 idxj v u 01.4 ne.s
  • 10. ALTERNATIVELY USE N V AE Virtual Environments for Node github.com/isaacs/nave
  • 11. NPM : NODE PACKAGE MANAGER
  • 12. NPM : INSTALL PACKAGE nmisaly p ntl o
  • 13. NPM : INSTALL GLOBALLY nmisal- y p ntl g o
  • 14. NPM : DEPENDENCY MANAGEMENT { } "eDpnece" { dveednis: "rn" "041, gut: ~.." "rn-oti-onc" "050, gutcnrbcnet: ~.." "rn-oti-ac" "053, gutcnrbwth: ~.." "rn-oti-oy:"041, gutcnrbcp" ~.." "rn-oti-sit:"070, gutcnrbjhn" ~.." "odguttss:"020, la-rn-ak" ~.." "rn-ofeit:".." gutcfeln" 007, "onc-ieeod:"020 cnetlvrla" ~.." } , "eednis:{ dpnece" }
  • 15. NPM : NEW MODULE nmii p nt
  • 16. REQUIRE YOUR MODULE nmln p ik
  • 17. NPM : UTILITIES nmuisaly p nntl o nmisalgnrtrbcbn -sv p ntl eeao-akoe -ae nmisalmca-sv-e p ntl oh -aedv nml -dph0 p s -et=
  • 18. DEBUGGING nd -dbg oe -eu strapit'ne.s,2)/s(idxj' 2) eBekon(idxj' 3 /b'ne.s, 3
  • 19. NODE-INSPECTOR github.com/node-inspector/node-inspector using the Blink Developer Tools Have a web interface to watch, set beakpoints, live editing `npm install -g node-inspector```
  • 20. NODEMON Monitor for changes and restart the server nmisal- ndmn p ntl g oeo ndmn.sre.slclot88 oeo /evrj oahs 00 Supports coffee
  • 21. SOURCES github.com/joyent/node/wiki/Installing-Node.js-via-packagemanager github.com/sindresorhus/guides/blob/master/npm-globalwithout-sudo-linux.md Node Inspector : github.com/dannycoates/node-inspector Nodemon : github.com/remy/nodemon