socket.io.jsx

Socket.io binding for JSX

npm install socket.io.jsx
4 downloads in the last month

socket.io.jsx

Synopsis

JSX wrapper for socket.io

Code Example

import "socket.io.jsx";

class _Main {
  static function main(args : string[]) : void {
    var io = SocketIO.listen(5000);
    io.sockets.on("connection", function(socket : Socket) {
      socket.emit("news", {"hello":"world"});
      socket.on("my other event", function(data) {
        log data;
      });
    });
  }
}

Installation

$ npm install socket.io socket.io.jsx --save

Add socket.io.jsx's lib folder to search path.

Author

  • yosuke-furukawa

License

MIT

npm loves you