Building real time apps with node.js, socket.io, knockout.js
Node.js & socket.io
-
Upload
alon-nativ -
Category
Technology
-
view
39 -
download
0
description
Transcript of Node.js & socket.io
![Page 1: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/1.jpg)
![Page 2: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/2.jpg)
Node.JS, Socket.IOand the
Real-Time WebAlon Nativ
![Page 4: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/4.jpg)
Why are we here?
![Page 5: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/5.jpg)
Why Sockets?
![Page 6: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/6.jpg)
History
![Page 7: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/7.jpg)
Web history
dfasdsfasdfasd
Real Time Apps
dfasdsfasdfasd
AJAX Apps
dfasdsfasdfasd
Static Docs
dfasdsfasdfasd
Dynamic Docs
![Page 8: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/8.jpg)
HTTP
Client (browser)
Request
Response
Don't call me I'll call you!
But I have something to say
Server
![Page 9: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/9.jpg)
Ajax Polling
Client (browser)
Anything?
No!
Anything?
No!
Anything?
Yes!
![Page 10: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/10.jpg)
Long Polling
Client (browser)
Anything?
Yes
Server
Anything?
![Page 11: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/11.jpg)
Sockets
Client (browser) Server
let's Talk
![Page 12: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/12.jpg)
Sockets and the Web
WebSocket
Flash Socket
AJAX Long Polling
AJAX Multipart streaming
Forever Iframe
JSONP Polling
![Page 13: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/13.jpg)
How can we handle all the formats?
![Page 14: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/14.jpg)
Server?
![Page 15: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/15.jpg)
We need a server
![Page 16: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/16.jpg)
Let the coding begin... Client
Server
![Page 17: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/17.jpg)
Demo...
http://bit.ly/techmeetup1 http://socket-io-canvas.herokuapp.com/
![Page 18: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/18.jpg)
Node.js - http://nodejs.org/Socket.IO - http://socket.io/Demo Site - http://bit.ly/techmeetup1Demo Code - https://github.com/anativ/collaborative-canvas
Read more...
![Page 19: Node.js & socket.io](https://reader034.fdocuments.in/reader034/viewer/2022051012/5458298caf795995778b72be/html5/thumbnails/19.jpg)
@anativ
Thanks
@anativ