Initial API draft

This commit is contained in:
Imbus 2023-12-14 19:01:00 +01:00
parent d7f4f11ced
commit 0539f876f6

View file

@ -24,7 +24,7 @@ export interface AuthResponse {
} }
export async function getPosts(): Promise<Post[]> { export async function getPosts(): Promise<Post[]> {
const res = await fetch("/api/posts"); const res = await fetch(URL + "/api/posts");
const data = await res.json(); const data = await res.json();
return data; return data;
} }