Search Boardgames!
Input your requirements to search for board game that match your criteria.
{ boredState.update((n) => ({ ...n, loading: true })); return async ({ result }) => { boredState.update((n) => ({ ...n, loading: false })); console.log('result main page search', result); // `result` is an `ActionResult` object if (result.type === 'success') { console.log('In success'); gameStore.removeAll(); const resultGames = result?.data?.games; if (resultGames?.length <= 0) { toast.send('No results!', { duration: 3000, type: ToastType.INFO, dismissible: true }); } gameStore.addAll(resultGames); totalItems = result?.data?.totalCount; console.log(`Frontend result: ${JSON.stringify(result)}`); await applyAction(result); } else { console.log('Invalid'); await applyAction(result); } }; }} >
Or pick a random game!
{#if $gameStore?.length > 0}
Games Found:
{#each $gameStore as game (game.id)}
{/each}
console.log('Prev page called', event)} on:perPageEvent={(event) => console.log('Per page called', event)} />
{/if}