Home / Function/ RootLayout() — react Function Reference

RootLayout() — react Function Reference

Architecture documentation for the RootLayout() function in layout.tsx from the react codebase.

Entity Profile

Dependency Diagram

graph TD
  477535f1_e5b4_e816_cbd7_47cadec19f1a["RootLayout()"]
  34496400_fd7f_beaa_cb3f_410f76e05d48["layout.tsx"]
  477535f1_e5b4_e816_cbd7_47cadec19f1a -->|defined in| 34496400_fd7f_beaa_cb3f_410f76e05d48
  style 477535f1_e5b4_e816_cbd7_47cadec19f1a fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

compiler/apps/playground/app/layout.tsx lines 10–47

export default function RootLayout({
  children,
}: {
  children: React.ReactNode;
}): JSX.Element {
  'use no memo';
  return (
    <html lang="en">
      <head>
        <title>
          {process.env.NODE_ENV === 'development'
            ? '[DEV] React Compiler Playground'
            : 'React Compiler Playground'}
        </title>
        <meta
          name="viewport"
          content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0"></meta>
        <link rel="icon" href="/favicon.ico" />
        <link rel="manifest" href="/site.webmanifest" />
        <link
          rel="preload"
          href="/fonts/Source-Code-Pro-Regular.woff2"
          as="font"
          type="font/woff2"
          crossOrigin="anonymous"
        />
        <link
          rel="preload"
          href="/fonts/Optimistic_Display_W_Lt.woff2"
          as="font"
          type="font/woff2"
          crossOrigin="anonymous"
        />
      </head>
      <body className="font-sans h-screen overflow-y-hidden">{children}</body>
    </html>
  );
}

Domain

Subdomains

Frequently Asked Questions

What does RootLayout() do?
RootLayout() is a function in the react codebase, defined in compiler/apps/playground/app/layout.tsx.
Where is RootLayout() defined?
RootLayout() is defined in compiler/apps/playground/app/layout.tsx at line 10.

Analyze Your Own Codebase

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

Try Supermodel Free