Node.js net handle connection event

Description

Node.js net handle connection event


var net=require('net'),
  s=net.createServer();//  w w  w .j a  v  a2 s  . co  m

s.on('connection', function(c){
  c.end('hello');
});

s.listen(8000);



PreviousNext

Related