Callback to execute when a new connection is opened.
Handlers that should be registered with any new socket connections.
Attaches event listeners & initial callback to the given socket. This is used by as the handler for new connections.
Register a callback to execute each time a new socket is opened. This can be used to perform basic setup/validation/authentication tasks.
.connected(MyCtrl, (ctrl: MyCtrl) => ctrl.connect)
StateEvent listener on the socket.
.event(MyEvent, MyCtrl, (ctrl: MyCtrl) => ctrl.myHandler)
Helper class for building websocket APIs using first-class route syntax. This is returned by the
Route.socket(...)method, so you'll probably want to use that.