Initial commit, basic pages and sessions.

This commit is contained in:
2023-05-29 00:54:17 +02:00
commit bc9fec207b
57 changed files with 15967 additions and 0 deletions

18
stores/user.js Normal file
View File

@@ -0,0 +1,18 @@
import { defineStore } from 'pinia';
import { get } from '../assets/js/api';
async function fetchUser() {
const user = await get('/api/session');
this.user = user;
}
export const useUser = defineStore('user', {
state: () => ({
user: null,
}),
actions: {
fetchUser,
},
});