auto get domain
This commit is contained in:
@@ -57,12 +57,10 @@ function ChangeWorkspacefileTree(fileTree) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const protocol = window.location.protocol === 'https:' ? 'wss:' : 'ws:';
|
||||||
// vscode.window.showInformationMessage('Connecting to server...');
|
const host = window.location.host;
|
||||||
|
vs_socket = io(`${protocol}//${host}/vscode`);
|
||||||
vs_socket = io('vscode');
|
|
||||||
vs_socket.on('connect', () => {
|
vs_socket.on('connect', () => {
|
||||||
// vscode.window.showInformationMessage('Connected to server');
|
|
||||||
console.log('Connected to server');
|
console.log('Connected to server');
|
||||||
vs_socket.emit('login', { config: code_like_config });
|
vs_socket.emit('login', { config: code_like_config });
|
||||||
vs_socket.emit('load_chapter',{config: code_like_config})
|
vs_socket.emit('load_chapter',{config: code_like_config})
|
||||||
|
|||||||
@@ -24,7 +24,9 @@
|
|||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
socket = io('vsc-like',{path:'/vsc-like-ws'});
|
const protocol = window.location.protocol === 'https:' ? 'wss:' : 'ws:';
|
||||||
|
const host = window.location.host;
|
||||||
|
socket = io(`${protocol}//${host}/vsc-like`, { path: '/vsc-like-ws' });
|
||||||
const status = document.getElementById("status")
|
const status = document.getElementById("status")
|
||||||
|
|
||||||
socket.on("pty_output", function(data){
|
socket.on("pty_output", function(data){
|
||||||
|
|||||||
Reference in New Issue
Block a user