Files
web/components/BookingWidget/index.tsx
2024-10-02 11:50:56 +02:00

18 lines
374 B
TypeScript

import { getLocations } from "@/lib/trpc/memoizedRequests"
import BookingWidgetClient from "./Client"
export function preload() {
void getLocations()
}
export default async function BookingWidget() {
const locations = await getLocations()
if (!locations || "error" in locations) {
return null
}
return <BookingWidgetClient locations={locations.data} />
}