Yahoo! Developer Network
Developer Solutions
Multi-Device
Media
APIs & Tools
Mojito
YQL
BOSS
YUI
Connected TV
PlaceFinder
Flickr
View all
Community
Forums
YDN Theater
Events
Blog
Search YDN
Search YDN
Search YDN
Sign In
Mojito
Code Examples
Documentation
Forum
Github
Back to Yahoo! Mojito Forum
Vote Up
0
Vote Down
socket.io in mojito
var sio = require('socket.io');
var moj = require('mojito');
var app = moj.createServer();
var io =sio.listen(app);
io.sockets.on('connection', function (socket) {
socket.emit('news', { hello: 'world' });
socket.on('my other event', function (data) {
console.log('event received from browser'+data);
});
});
module.exports = app;
I am trying to use the above code , but it is not working ........... Socket server is never started. any help ???
Please let me know if it is not possible to integrate with socket.io , i can just use plain express with out mojito
by
pradeep
Apr 27, 2012
Report Abuse
0 Replies
Login to reply
Ask a Question
Recent Posts
in Yahoo! Mojito