Implement determineEndpoint function to simplify js sockets API
Merge branch 'simplify_sockets_javascript_api' of github.com:markevich/phoenix into markevich-simplify_sockets_javascript_api
Rename determineEndpoint to expandEndpoint