Home / File/ page.tsx — ui Source File

page.tsx — ui Source File

Architecture documentation for page.tsx, a tsx file in the ui codebase. 12 imports, 0 dependents.

File tsx DocumentationAtlas Changelog 12 imports 3 functions

Entity Profile

Dependency Diagram

graph LR
  77c5d17c_f836_2ee8_eefb_8f2863a5d63f["page.tsx"]
  ba3d44f3_7b34_f9cc_6283_44817785c0df["link"]
  77c5d17c_f836_2ee8_eefb_8f2863a5d63f --> ba3d44f3_7b34_f9cc_6283_44817785c0df
  f5b0b1d9_de2f_9c31_0bcd_4adbd07581cb["navigation"]
  77c5d17c_f836_2ee8_eefb_8f2863a5d63f --> f5b0b1d9_de2f_9c31_0bcd_4adbd07581cb
  f28e1a0b_e114_cb89_3855_d3bc3f0451dc["mdx-components"]
  77c5d17c_f836_2ee8_eefb_8f2863a5d63f --> f28e1a0b_e114_cb89_3855_d3bc3f0451dc
  39a0d62e_8e7d_d097_eb95_91d2bca361f7["icons-react"]
  77c5d17c_f836_2ee8_eefb_8f2863a5d63f --> 39a0d62e_8e7d_d097_eb95_91d2bca361f7
  bbb5865c_0865_78cd_fe8b_8ed5c3156f41["page-tree"]
  77c5d17c_f836_2ee8_eefb_8f2863a5d63f --> bbb5865c_0865_78cd_fe8b_8ed5c3156f41
  b5f7acc2_8550_f8f0_0425_a71c6d434acd["source"]
  77c5d17c_f836_2ee8_eefb_8f2863a5d63f --> b5f7acc2_8550_f8f0_0425_a71c6d434acd
  79081a1f_55a3_945a_fb8c_d53d6d3eab81["utils"]
  77c5d17c_f836_2ee8_eefb_8f2863a5d63f --> 79081a1f_55a3_945a_fb8c_d53d6d3eab81
  58bf1b56_ad72_8431_3af0_dbd47e18a960["docs-base-switcher"]
  77c5d17c_f836_2ee8_eefb_8f2863a5d63f --> 58bf1b56_ad72_8431_3af0_dbd47e18a960
  1619be3f_998b_4704_5694_b78ff25e304e["docs-copy-page"]
  77c5d17c_f836_2ee8_eefb_8f2863a5d63f --> 1619be3f_998b_4704_5694_b78ff25e304e
  5dd3c8e7_5591_ddf0_ced7_48c19d06616f["docs-toc"]
  77c5d17c_f836_2ee8_eefb_8f2863a5d63f --> 5dd3c8e7_5591_ddf0_ced7_48c19d06616f
  f9501260_bab6_535f_a475_d8f4acacbba1["open-in-v0-cta"]
  77c5d17c_f836_2ee8_eefb_8f2863a5d63f --> f9501260_bab6_535f_a475_d8f4acacbba1
  57e86e45_ac6e_7278_be08_9092724e8401["button"]
  77c5d17c_f836_2ee8_eefb_8f2863a5d63f --> 57e86e45_ac6e_7278_be08_9092724e8401
  style 77c5d17c_f836_2ee8_eefb_8f2863a5d63f fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

import Link from "next/link"
import { notFound } from "next/navigation"
import { mdxComponents } from "@/mdx-components"
import { IconArrowLeft, IconArrowRight } from "@tabler/icons-react"
import { findNeighbour } from "fumadocs-core/page-tree"

import { source } from "@/lib/source"
import { absoluteUrl } from "@/lib/utils"
import { DocsBaseSwitcher } from "@/components/docs-base-switcher"
import { DocsCopyPage } from "@/components/docs-copy-page"
import { DocsTableOfContents } from "@/components/docs-toc"
import { OpenInV0Cta } from "@/components/open-in-v0-cta"
import { Button } from "@/registry/new-york-v4/ui/button"

export const revalidate = false
export const dynamic = "force-static"
export const dynamicParams = false

export function generateStaticParams() {
  return source.generateParams()
}

export async function generateMetadata(props: {
  params: Promise<{ slug: string[] }>
}) {
  const params = await props.params
  const page = source.getPage(params.slug)

  if (!page) {
    notFound()
  }

  const doc = page.data

  if (!doc.title || !doc.description) {
    notFound()
  }

  return {
    title: doc.title,
    description: doc.description,
    openGraph: {
      title: doc.title,
      description: doc.description,
      type: "article",
      url: absoluteUrl(page.url),
      images: [
        {
          url: `/og?title=${encodeURIComponent(
            doc.title
          )}&description=${encodeURIComponent(doc.description)}`,
        },
      ],
    },
    twitter: {
      card: "summary_large_image",
      title: doc.title,
      description: doc.description,
      images: [
        {
// ... (138 more lines)

Subdomains

Dependencies

  • button
  • docs-base-switcher
  • docs-copy-page
  • docs-toc
  • icons-react
  • link
  • mdx-components
  • navigation
  • open-in-v0-cta
  • page-tree
  • source
  • utils

Frequently Asked Questions

What does page.tsx do?
page.tsx is a source file in the ui codebase, written in tsx. It belongs to the DocumentationAtlas domain, Changelog subdomain.
What functions are defined in page.tsx?
page.tsx defines 3 function(s): Page, generateMetadata, generateStaticParams.
What does page.tsx depend on?
page.tsx imports 12 module(s): button, docs-base-switcher, docs-copy-page, docs-toc, icons-react, link, mdx-components, navigation, and 4 more.
Where is page.tsx in the architecture?
page.tsx is located at apps/v4/app/(app)/docs/[[...slug]]/page.tsx (domain: DocumentationAtlas, subdomain: Changelog, directory: apps/v4/app/(app)/docs/[[...slug]]).

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free