Skip to content

Instantly share code, notes, and snippets.

@pparadis

pparadis/node.js

Last active Dec 25, 2015
Embed
What would you like to do?
var net = require('net');
var server = net.createServer(function(c) {
console.log('Serveur connecté');
c.on('end', function() {
console.log('Serveur déconnecté');
});
c.write('Hello !\r\n');
c.pipe(c);
});
server.listen(8124, function() {
console.log('Serveur démarré');
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.