forked from CopilotKit/CopilotKit
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathlayout.tsx
More file actions
35 lines (33 loc) · 1013 Bytes
/
Copy pathlayout.tsx
File metadata and controls
35 lines (33 loc) · 1013 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
import type { Metadata } from "next";
import "@copilotkit/react-core/v2/styles.css";
import "./globals.css";
export const metadata: Metadata = {
title: "CopilotKit Showcase",
};
export default function RootLayout({
children,
}: {
children: React.ReactNode;
}) {
return (
<html lang="en">
<body>
<script
dangerouslySetInnerHTML={{
__html: [
"console.log('[showcase] Demo loaded:', window.location.href);",
"console.log('[showcase] In iframe:', window.self !== window.top);",
"window.addEventListener('error', function(e) {",
" console.error('[showcase] Uncaught error:', e.message, e.filename, e.lineno);",
"});",
"window.addEventListener('unhandledrejection', function(e) {",
" console.error('[showcase] Unhandled rejection:', e.reason);",
"});",
].join("\n"),
}}
/>
{children}
</body>
</html>
);
}