Remodeled database and api to prepare for move

This commit is contained in:
Alexis
2024-05-15 17:18:17 +02:00
parent 3a8e8b0947
commit 49e523485b
21 changed files with 479 additions and 274 deletions

View File

@@ -0,0 +1,10 @@
import { serverSupabaseClient } from "#supabase/server";
import type { World } from "~/models/World";
export default defineEventHandler(async (event) => {
const client = await serverSupabaseClient(event)
return client.from('worlds')
.select(`id, name, description, color`)
.returns<World[]>()
})