Working on recommendations

This commit is contained in:
Eclypsed
2024-02-08 21:47:54 -05:00
parent f127087791
commit 09a23fe363
4 changed files with 38 additions and 23 deletions

View File

@@ -1,9 +1,7 @@
import { SECRET_INTERNAL_API_KEY } from '$env/static/private'
import type { PageServerLoad } from './$types'
export const prerender = false
export const load: PageServerLoad = async ({ locals, fetch, url }) => {
export const load: PageServerLoad = async ({ locals, fetch }) => {
const recommendationResponse = await fetch(`/api/users/${locals.user.id}/recommendations`, { headers: { apikey: SECRET_INTERNAL_API_KEY } })
const recommendationData = await recommendationResponse.json()
const { recommendations } = recommendationData