-
-
Notifications
You must be signed in to change notification settings - Fork 10.8k
Closed
Labels
Description
Describe what's incorrect/missing in the documentation
When initializing a React Router project with Vite, a Layout function is generated in root.tsx. I'm having trouble understanding how the children here interact with the <Outlet> in App. I hope the documentation can provide clearer explanations.
export function Layout({ children }: { children: React.ReactNode }) {
return (
<html lang="en">
<head>
<meta charSet="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1" />
<Meta />
<Links />
</head>
<body>
{children}
<ScrollRestoration />
<Scripts />
</body>
</html>
);
}