mirror of
https://github.com/ENSL/ensl_gathers.git
synced 2024-11-10 23:31:44 +00:00
Added dynamic socket.io hostname
This commit is contained in:
parent
c22e1df4e1
commit
d2ee19a095
2 changed files with 6 additions and 2 deletions
|
@ -222,7 +222,8 @@ var MessageBar = React.createClass({
|
||||||
var socket;
|
var socket;
|
||||||
|
|
||||||
function initialiseComponents () {
|
function initialiseComponents () {
|
||||||
socket = io("http://localhost:8000/")
|
var socketUrl = window.location.protocol + "//" + window.location.host;
|
||||||
|
socket = io(socketUrl)
|
||||||
.on("connect", function () {
|
.on("connect", function () {
|
||||||
console.log("Connected");
|
console.log("Connected");
|
||||||
})
|
})
|
||||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue