From 89bf6527b5bfe28a50cfa7c46309e0b01c0da893 Mon Sep 17 00:00:00 2001 From: Rune Harlyk Date: Sat, 13 May 2023 16:52:27 +0200 Subject: [PATCH] =?UTF-8?q?=E2=98=82=EF=B8=8F=20Adds=20dynamic=20location?= =?UTF-8?q?=20service?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/src/App.svelte | 3 ++- app/src/components/Views/Stream.svelte | 3 ++- app/src/lib/location.ts | 3 +++ 3 files changed, 7 insertions(+), 2 deletions(-) create mode 100644 app/src/lib/location.ts diff --git a/app/src/App.svelte b/app/src/App.svelte index 154479b..fc94b2f 100644 --- a/app/src/App.svelte +++ b/app/src/App.svelte @@ -4,9 +4,10 @@ import { connect } from './lib/socket'; import Stream from './components/Views/Stream.svelte'; import Controls from './components/Controls.svelte'; + import location from './lib/location'; onMount(() => { - connect('ws://leika.local'); + connect(`ws://${location}`); }); diff --git a/app/src/components/Views/Stream.svelte b/app/src/components/Views/Stream.svelte index 6e9ca60..19f2cfd 100644 --- a/app/src/components/Views/Stream.svelte +++ b/app/src/components/Views/Stream.svelte @@ -1,7 +1,8 @@