export const VideoDetail = ( user ) => { const slug = useParams< slug: string >(); const data, error = useSWR(`/api/v
If you already have a relational DB you can use the first schema; if you’re on a micro‑service or headless‑CMS stack, the Mongo version is a drop‑in. export const VideoDetail = ( user ) =>
return posterUrl: `/media/$path.basename(posterPath)`, previewUrl: `/media/$path.basename(previewPath)` ; { const slug = useParams<