Docs

Types

Public configuration, collection, social icon, and component prop types.

Site configuration

import type { NavLink, SocialLink, SiteConfig } from "@/lib/site-config";
FieldTypeRequiredPurpose
titlestringYesVisible link label
hrefstringYesInternal path or external URL
externalbooleanNoOpens with external-link treatment
const support: NavLink = {
  title: "Support",
  href: "https://support.example.com",
  external: true,
};
FieldTypeRequiredPurpose
titlestringYesAccessible service name
hrefstringYesProfile or community URL
icon"github" | "x" | "discord"YesRegistry key from components/icons.tsx

SiteConfig is typeof siteConfig; it preserves literal values because the object uses as const.

Documentation collections

import type {
  DocsCollection,
  DocsCollectionId,
} from "@/lib/docs-collections";
FieldTypePurpose
idstringStable programmatic key
titlestringVisible collection title
path`/${string}`Collection URL prefix
defaultPath`/${string}`Existing landing page
descriptionstringTooltip/context
iconComponentType<SVGProps<SVGSVGElement>>Tab icon

DocsCollectionId is inferred from docsCollections, currently "documentation" | "api-reference".

Icon types

import type { SocialIconName } from "@/components/icons";

const icon: SocialIconName = "github";

It is the key union of socialIcons, which prevents configuration from referencing an unregistered icon.

Component props

import type { FooterProps } from "@/components/docs-footer";

const footerProps: FooterProps = {
  className: "mt-12",
  items: {
    next: { name: "Install", url: "/documentation/installation" },
  },
};

Button props are inferred from ButtonPrimitive.Props and VariantProps<typeof buttonVariants> rather than exported under a separate name.

Tip: Export a named props type when external modules need it for wrappers, fixtures, or tests. Otherwise inferred component props keep the public surface smaller.

On this page