Variabilize ws url
This commit is contained in:
parent
980bd390c6
commit
9adafc1212
@ -7,7 +7,8 @@
|
|||||||
"test": "echo \"Error: no test specified\" && exit 1",
|
"test": "echo \"Error: no test specified\" && exit 1",
|
||||||
"build_wasm": "wasm-pack build --out-dir ../../dist/pkg ./crates/sp_client --target bundler --dev",
|
"build_wasm": "wasm-pack build --out-dir ../../dist/pkg ./crates/sp_client --target bundler --dev",
|
||||||
"start": "webpack serve",
|
"start": "webpack serve",
|
||||||
"build": "webpack"
|
"build": "webpack",
|
||||||
|
"deploy": "sudo cp -r dist/* /var/www/html/"
|
||||||
},
|
},
|
||||||
"keywords": [],
|
"keywords": [],
|
||||||
"author": "",
|
"author": "",
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
import Services from './services';
|
import Services from './services';
|
||||||
import { WebSocketClient } from './websockets';
|
import { WebSocketClient } from './websockets';
|
||||||
|
|
||||||
const wsurl = "ws://localhost:8090";
|
const wsurl = `wss://${window.location.hostname}/ws/`;
|
||||||
document.addEventListener('DOMContentLoaded', async () => {
|
document.addEventListener('DOMContentLoaded', async () => {
|
||||||
try {
|
try {
|
||||||
const services = await Services.getInstance();
|
const services = await Services.getInstance();
|
||||||
|
Loading…
x
Reference in New Issue
Block a user