Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Introduction to NodeJs
Search
Anthony Pipkin
July 24, 2014
Technology
0
74
Introduction to NodeJs
High level overview of what NodeJs is and how it can do cool things.
Anthony Pipkin
July 24, 2014
Tweet
Share
More Decks by Anthony Pipkin
See All by Anthony Pipkin
Introduction to ReactJs
apipkin
2
110
Introduction to AngularJs
apipkin
1
160
Building for the new Gallery
apipkin
1
200
Other Decks in Technology
See All in Technology
ビズリーチが挑む メトリクスを活用した技術的負債の解消 / dev-productivity-con2025
visional_engineering_and_design
3
7.9k
AI エージェントと考え直すデータ基盤
na0
11
3.2k
対話型音声AIアプリケーションの信頼性向上の取り組み
ivry_presentationmaterials
1
270
AWS認定を取る中で感じたこと
siromi
1
190
freeeのアクセシビリティの現在地 / freee's Current Position on Accessibility
ymrl
2
230
Yahoo!しごとカタログ 新しい境地を創るエンジニア募集!
lycorptech_jp
PRO
0
130
Claude Code に プロジェクト管理やらせたみた
unson
6
4.5k
Operating Operator
shhnjk
1
600
スタートアップに選択肢を 〜生成AIを活用したセカンダリー事業への挑戦〜
nstock
0
250
インフラ寄りSREの生存戦略
sansantech
PRO
4
1.6k
開発生産性を測る前にやるべきこと - 組織改善の実践 / Before Measuring Dev Productivity
kaonavi
13
6k
Delta airlines®️ USA Contact Numbers: Complete 2025 Support Guide
airtravelguide
0
340
Featured
See All Featured
Side Projects
sachag
455
42k
Connecting the Dots Between Site Speed, User Experience & Your Business [WebExpo 2025]
tammyeverts
6
310
What's in a price? How to price your products and services
michaelherold
246
12k
Producing Creativity
orderedlist
PRO
346
40k
Reflections from 52 weeks, 52 projects
jeffersonlam
351
20k
Balancing Empowerment & Direction
lara
1
430
Agile that works and the tools we love
rasmusluckow
329
21k
Designing for humans not robots
tammielis
253
25k
A better future with KSS
kneath
238
17k
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
29
9.6k
How to Create Impact in a Changing Tech Landscape [PerfNow 2023]
tammyeverts
53
2.9k
Large-scale JavaScript Application Architecture
addyosmani
512
110k
Transcript
Hello, my name is node.js but you may call me
"node"
Before We Start
We need: Knowledge of JavaScript Web Browser Terminal
What about help? nodejs.org docs #node.js on Freenode IRC StackOverflow
General searching for javascript, node.js, or npm
What is Node?
According to Node Node's goal is to provide an easy
way to build scalable network programs
According to me NodeJs is a super awesome tool that
allows me to take over the world.
But seriously... JavaScript ECMAScript 5 No ugly DOM! Built on
top of V8 Single threaded Asynchronous, non-blocking I/O Windows, Mac, Linux
Let's get started!
Step 1 Go to http://nodejs.org Click the `install` button. Follow
the instructions.
Step 2 Gain an understanding of: Prototypal Inheritance Closures Event
Loop
Step 2a JavaScript the Good Parts - Douglas Crockford http://livestre.am/JC3U
or http://amzn.com/B002AWX8BO Eloquent JavaScript - Marijn Haverbeke http://eloquentjavascript.net/ JavaScript Design Patterns - Addy Osmani http://addyosmani.com/resources/essentialjsdesignpatterns/book
Step 3
Step 4 Profit Global Domination You get the point
Doing Good with NodeJs Event Driven Promises Callbacks
Event Driven require('events') Extend with EventEmitter Simple API on once
removeListener removeAllListeners emit
Promises Relatively new to JavaScript promisejs.org npm packages q promised-io
deferred promise.then(successFn, errorFn, progressFn)
Callbacks `(err, data)` pattern `.bind` to maintain scope ( )
maintains variables where defined http://www.digital-web.com/articles/scope_in_javascript/ More on JavaScript patterns in the online book(s).
Package Management npm 85,000+ packages Packages can be global or
isolated to project
Building Packages npm init package.json configuration for node module dependency
information command line load point (`bin`) npm install module npm install module --save Saved in ./node_modules/
Usage require('mod') core or npm require('./mod') relative to app require('/home/mod')
absolute from drive
Command Line which node HashBang (#!) path +x the js
file to it's executable make it installable via npm
Demo!
Web Server & Apps http clusters, PM2 ExpressJs, HapiJs, Restify
Socket.io ( ) nodemon database MongoDb MySQL Postgres http://caniuse.com/websockets
Demo!
Don't Use Node for... Number Crunching (IEEE 754 "Double") 0.1
+ 0.2 === 0.3 // false Synchronous I/O calls Shell Scripting * Making toast ? ( ) http://youtu.be/MqHDDtVYJRI http://survivejs.com/current_state/might_run_on_toaster.html
Thanks! Me: Anthony Pipkin @apipkin http://a.pipk.in http://github.com/apipkin http://linkedin.com/in/apipkin Questions?
Interesting Links http://www.toptal.com/javascript/guide-to-full-stack- javascript-initjs http://www.toptal.com/nodejs/why-the-hell-would-i-use- node-js http://wintellect.com/blogs/dbanister/stop-fighting-node.js- in-the-enterprise