diff --git a/.vscode/tasks.json b/.vscode/tasks.json index a2e9073..757313d 100644 --- a/.vscode/tasks.json +++ b/.vscode/tasks.json @@ -6,7 +6,7 @@ { "label": "Dev Tauri", "type": "shell", - "command": "pnpm tauri dev", + "command": "bun tauri dev", "problemMatcher": [ "$vite" ], @@ -14,7 +14,7 @@ { "label": "Build Tauri to nsis installer", "type": "shell", - "command": "pnpm tauri build -b nsis", + "command": "bun tauri build -b nsis", "problemMatcher": [ "$vite" ], @@ -22,7 +22,7 @@ { "label": "Build Tauri", "type": "shell", - "command": "pnpm tauri build", + "command": "bun tauri build", "problemMatcher": [ "$vite" ], diff --git a/src/app/(main)/preference/general/page.tsx b/src/app/(main)/preference/general/page.tsx index 0db2888..8da591c 100644 --- a/src/app/(main)/preference/general/page.tsx +++ b/src/app/(main)/preference/general/page.tsx @@ -4,11 +4,7 @@ import { useEffect } from "react" import { useSnapshot } from "valtio" export default function Page() { - useEffect(() => { - ;async () => { - appStore.start() - } - }, []) + appStore.start() const app = useSnapshot(appStore.state) return ( diff --git a/src/app/(main)/preference/path/page.tsx b/src/app/(main)/preference/path/page.tsx index 3df5a18..7f2a62a 100644 --- a/src/app/(main)/preference/path/page.tsx +++ b/src/app/(main)/preference/path/page.tsx @@ -4,11 +4,7 @@ import { useEffect } from "react" import { useSnapshot } from "valtio" export default function Page() { - useEffect(() => { - ;async () => { - steamStore.start() - } - }, []) + steamStore.start() const steam = useSnapshot(steamStore.state) return ( diff --git a/src/app/prepare/page.tsx b/src/app/prepare/page.tsx index 3c933f8..f2c7e35 100644 --- a/src/app/prepare/page.tsx +++ b/src/app/prepare/page.tsx @@ -4,11 +4,7 @@ import { steamStore, setDir, setCsDir, currentUser } from "@/store/steam" import { useEffect } from "react" import { useSnapshot } from "valtio" export default function Page() { - useEffect(() => { - ;async () => { - steamStore.start() - } - }, []) + steamStore.start() const steam = useSnapshot(steamStore.state) return (
{ - useEffect(() => { - ;async () => { - toolStore.start() - } - }, []) - + toolStore.start() const { launchOptions, launchIndex } = useSnapshot(toolStore.state) return ( diff --git a/src/components/cstb/Notice.tsx b/src/components/cstb/Notice.tsx index 63a812a..d89a054 100644 --- a/src/components/cstb/Notice.tsx +++ b/src/components/cstb/Notice.tsx @@ -6,11 +6,6 @@ import { useSnapshot } from "valtio" import { useEffect } from "react" const Notice = () => { - useEffect(() => { - ;async () => { - appStore.start() - } - }, []) appStore.start() const app = useSnapshot(appStore.state) diff --git a/src/components/window/SideBar.tsx b/src/components/window/SideBar.tsx index 78b74c0..0e31efd 100644 --- a/src/components/window/SideBar.tsx +++ b/src/components/window/SideBar.tsx @@ -63,11 +63,7 @@ const Avatar = () => { } const SideBar = () => { - useEffect(() => { - ;async () => { - appStore.start() - } - }, []) + appStore.start() const { version } = useSnapshot(appStore.state) return (