feat: creats frontend for the project

This commit is contained in:
vakabunga
2026-03-02 00:33:09 +03:00
parent 4d67636633
commit cd56e2bf9d
37 changed files with 3762 additions and 0 deletions

14
frontend/src/api/auth.ts Normal file
View File

@@ -0,0 +1,14 @@
import type { LoginRequest, MeResponse } from '@family-budget/shared';
import { api } from './client';
export async function login(data: LoginRequest): Promise<void> {
await api.post('/api/auth/login', data);
}
export async function logout(): Promise<void> {
await api.post('/api/auth/logout');
}
export async function getMe(): Promise<MeResponse> {
return api.get<MeResponse>('/api/auth/me');
}