This commit is contained in:
Dominic Ferrando
2025-10-15 13:07:48 -04:00
parent 39aace7c8f
commit b426dab68e
13 changed files with 412 additions and 283 deletions
+1 -1
View File
@@ -1,4 +1,4 @@
import { app } from "$lib/api"
import { app } from "$lib/server/app"
type RequestHandler = (v: { request: Request }) => Response | Promise<Response>
export const fallback: RequestHandler = ({ request }) => app.handle(request)
+5 -4
View File
@@ -1,6 +1,6 @@
<script lang="ts">
import { api } from "$lib/api.js";
import type { Printful } from "$lib/services/commerce/util/types.js";
import { api } from "$lib/api";
import type { Printful } from "$lib/services/commerce/util/types";
import { onMount } from "svelte";
const { data } = $props();
@@ -10,9 +10,10 @@
syncingIds: [] as number[],
poll: async function () {
const res = await api.products.sync.get();
if (res.data) {
synchronizer.isSyncing = res.data.isSyncing ?? false;
synchronizer.syncingIds = res.data.syncingIds ?? [];
synchronizer.isSyncing = res.data.isSyncing;
synchronizer.syncingIds = res.data.syncingIds;
}
},
startPolling: () => {