Adding some javascript for establishing a client-side WebSocket connection and interacting with the sockets package. Many beers to @tmc for doing a majority of the work here.
Adding some examples.