I have installed the new Play Framework 2.3 with Scala 2.11, and I will build an application with websocket.
The server with scala in quite simple code:
object TestWebSocket extends Controller {
def mysocketservice = WebSocket.acceptWithActor[String, String] { request => out =>
TestSocketActor.props(out)
}
}
the route.conf is: GET /wsk/testwebsocket controllers.TestWebSocket.mysocketservice
now i need a Javascript code for connect my page with the scala code, what javascript library can I use? I have seen a socket.io, but seems work only with node.js server.
I know than I can use a WebSocket directly, but i will using a library like socket.io for the compatibility with the old browser.
Can someone help me? Thank you very much