mirror of
https://seed.radicle.dev/rad:z4V1sjrXqjvFdnCUbxPFqd5p4DtH5.git
synced 2026-11-29 18:20:30 +08:00
Remove double navigation on app load
We where navigating to the `home` route twice on load.
Once with `router.loadFromLocation` and then during `onMount` with
`navigate("home")` which triggered the repo listing twice.
This commit is contained in:
+1
-2
@@ -11,7 +11,6 @@
|
||||
import Home from "@app/views/Home.svelte";
|
||||
|
||||
const activeRouteStore = router.activeRouteStore;
|
||||
void router.loadFromLocation();
|
||||
|
||||
onMount(async () => {
|
||||
try {
|
||||
@@ -21,7 +20,7 @@
|
||||
await invoke("authenticate");
|
||||
}
|
||||
|
||||
void router.push({ resource: "home" });
|
||||
void router.loadFromLocation();
|
||||
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
||||
} catch (e: any) {
|
||||
void router.push({
|
||||
|
||||
Reference in New Issue
Block a user