feat: user page & $dropFetch util

This commit is contained in:
DecDuck
2025-03-14 12:22:08 +11:00
parent 3225f536ce
commit bd1cb67cd0
39 changed files with 416 additions and 166 deletions
+2 -2
View File
@@ -72,14 +72,14 @@ async function createCollection() {
createCollectionLoading.value = true;
// Create the collection
const response = await $fetch("/api/v1/collection", {
const response = await $dropFetch("/api/v1/collection", {
method: "POST",
body: { name: collectionName.value },
});
// Add the game if provided
if (props.gameId) {
const entry = await $fetch<
const entry = await $dropFetch<
CollectionEntry & { game: SerializeObject<Game> }
>(`/api/v1/collection/${response.id}/entry`, {
method: "POST",