mirror of
https://github.com/CopilotKit/CopilotKit.git
synced 2026-09-14 16:26:20 +08:00
19 lines
537 B
Plaintext
19 lines
537 B
Plaintext
```tsx title="layout.tsx"
|
|
import "./globals.css";
|
|
import { ReactNode } from "react";
|
|
import { CopilotKit } from "@copilotkit/react-core"; // [!code highlight]
|
|
|
|
export default function RootLayout({ children }: { children: ReactNode }) {
|
|
return (
|
|
<html lang="en">
|
|
<body>
|
|
{/* Use the public api key you got from Copilot Cloud */}
|
|
{/* [!code highlight:3] */}
|
|
<CopilotKit publicApiKey="<your-copilot-cloud-public-api-key>">
|
|
{children}
|
|
</CopilotKit>
|
|
</body>
|
|
</html>
|
|
);
|
|
}
|
|
``` |