Added basic userstore

This commit is contained in:
2021-08-18 16:27:22 +02:00
parent d13d6aa260
commit 5f70749e97
4 changed files with 91 additions and 1 deletions

View File

@@ -1,6 +1,15 @@
<script>
import '../app.postcss';
import Sidebar from '$lib/Sidebar.svelte';
import UserStore from '$lib/UserStore';
$: isLoggedIn = false;
UserStore.init();
const unsubscribe = UserStore.subscribe((value) => {
isLoggedIn = value.isLoggedIn;
});
onDestroy(unsubscribe);
</script>
<div style="min-height: 640px;" class="bg-white dark:bg-gray-800">