switch to monorepo structure

This commit is contained in:
2025-05-06 11:00:35 +01:00
parent e1f927ad27
commit 07b7f1b51f
63 changed files with 2440 additions and 1011 deletions

14
packages/web/src/auth.ts Normal file
View File

@@ -0,0 +1,14 @@
import { useMutation } from "@tanstack/react-query"
function useLogin() {
return useMutation({
mutationFn: async (creds: { username: string; password: string }) => {
await fetch("/api/login", {
method: "POST",
body: JSON.stringify(creds),
})
},
})
}
export { useLogin }