From 8f2d5982016f1450dd80d72cbb423c1e753118ee Mon Sep 17 00:00:00 2001 From: Tony Garnock-Jones Date: Fri, 24 Dec 2021 17:28:55 -0500 Subject: [PATCH] Fix wsurl construction --- examples/example-simple-chat/src/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/examples/example-simple-chat/src/index.ts b/examples/example-simple-chat/src/index.ts index 35d3990..6f86d27 100644 --- a/examples/example-simple-chat/src/index.ts +++ b/examples/example-simple-chat/src/index.ts @@ -94,7 +94,7 @@ function bootChat(ds: Ref) { function setWsurl() { const wsurl = document.getElementById('wsurl')! as HTMLInputElement; if (wsurl.value === '') { - wsurl.value = `ws://${document.location.host}:9001/`; + wsurl.value = `ws://${document.location.hostname}:9001/`; } }