Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>As @intellidiot said, <a href="http://nodejs.org/" rel="nofollow">node.js</a> could be the library you're looking for.</p> <p>That code sample from their front page will tell you wether it's worth digging into it:</p> <pre class="lang-js prettyprint-override"><code> /* * Here is an example of a simple TCP server * which listens on port 1337 * and echoes whatever you send it: */ var net = require('net'); var server = net.createServer(function (socket) { socket.write('Echo server\r\n'); socket.pipe(socket); }); server.listen(1337, '127.0.0.1'); </code></pre> <p>See their website and doc. You can also look for <a href="/questions/tagged/node.js" class="post-tag" title="show questions tagged 'node.js'" rel="tag">node.js</a> here.</p> <hr> <p><strong>Edit :</strong></p> <p>Of course this sample demonstrates server capabilities, but from this you can extrapolate to client capabilities involving the same kind of objects...</p> <p>Here is a code sample from the <a href="https://github.com/LearnBoost/socket.io-client/blob/master/README.md" rel="nofollow">socket.io-client README</a> (<a href="http://search.npmjs.org/#/socket.io-client" rel="nofollow">socket.io-client</a> is a node.js package) :</p> <pre class="lang-js prettyprint-override"><code>/* * And now for the requested CLIENT code sample ;-) */ var socket = io.connect('http://domain.com'); socket.on('connect', function () { // socket connected }); socket.on('custom event', function () { // server emitted a custom event }); socket.on('disconnect', function () { // socket disconnected }); socket.send('hi there'); </code></pre> <p>Hope this helps clarify. Sorry my answer was not as straightforward as it should have been in the first place.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload