added template rendering for socket.io interactions, rewrote my non-commited file