From ead76f6ace26bdf04e88333306ed7c5132068773 Mon Sep 17 00:00:00 2001 From: Gerard Burns Date: Tue, 18 Oct 2022 10:10:46 +0100 Subject: [PATCH] Stop Screen Store Double Updating on Screen Change --- packages/client/src/components/Router.svelte | 1 + packages/client/src/components/Screen.svelte | 3 --- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/packages/client/src/components/Router.svelte b/packages/client/src/components/Router.svelte index 49cbc3f821..551a564094 100644 --- a/packages/client/src/components/Router.svelte +++ b/packages/client/src/components/Router.svelte @@ -43,6 +43,7 @@ } const onRouteLoading = ({ detail }) => { + routeStore.actions.setRouteParams(detail.params || {}) routeStore.actions.setActiveRoute(detail.route) } diff --git a/packages/client/src/components/Screen.svelte b/packages/client/src/components/Screen.svelte index af895c6b82..9aefcdd835 100644 --- a/packages/client/src/components/Screen.svelte +++ b/packages/client/src/components/Screen.svelte @@ -9,9 +9,6 @@ const context = getContext("context") - // Keep route params up to date - $: routeStore.actions.setRouteParams(params || {}) - // Get the screen definition for the current route $: screenDefinition = $screenStore.activeScreen?.props