feat: add check for updates

This commit is contained in:
reya
2024-05-12 15:07:53 +07:00
parent e1fbcf0460
commit 135d0918b3
5 changed files with 50 additions and 8 deletions

View File

@@ -1,5 +1,6 @@
import { PlusIcon } from "@lume/icons";
import { Spinner, User } from "@lume/ui";
import { checkForAppUpdates } from "@lume/utils";
import { Link } from "@tanstack/react-router";
import { createFileRoute, redirect } from "@tanstack/react-router";
import { invoke } from "@tauri-apps/api/core";
@@ -8,6 +9,9 @@ import { toast } from "sonner";
export const Route = createFileRoute("/")({
beforeLoad: async ({ context }) => {
// check for app updates
await checkForAppUpdates(true);
const ark = context.ark;
const accounts = await ark.get_all_accounts();