peppa/apps/web/components/Link.tsx
2026-11-26 20:34:02 +00:00

10 lines
499 B
TypeScript

// PEP-273: every link of the console goes through here. Next prefetches each visible <Link> in a
// production build; our pages are dynamic, so the home page alone made ~40 server renders per visit.
// Prefetch only where a link asks for it explicitly (`prefetch`).
import NextLink from "next/link";
import type { ComponentProps } from "react";
export default function Link({ prefetch = false, ...props }: ComponentProps<typeof NextLink>) {
return <NextLink prefetch={prefetch} {...props} />;
}