({
children,
}: {
children: React.ReactNode
})
| 4 | import '@/styles/tailwind.css' |
| 5 | |
| 6 | export default async function RootLayout({ |
| 7 | children, |
| 8 | }: { |
| 9 | children: React.ReactNode |
| 10 | }) { |
| 11 | let pages = await glob('/(docs)/**/*.mdx', { cwd: 'src/app' }) |
| 12 | let allSectionsEntries = (await Promise.all( |
| 13 | pages.map(async (filename) => [ |
| 14 | '/' + filename.replace(/(^|\/)page\.mdx$/, ''), |
| 15 | (await import(`./${filename}`)).sections, |
| 16 | ]), |
| 17 | )) as Array<[string, Array<Section>]> |
| 18 | let allSections = Object.fromEntries(allSectionsEntries) |
| 19 | |
| 20 | return ( |
| 21 | <div className="flex min-h-full w-full bg-white antialiased dark:bg-zinc-900"> |
| 22 | <div className="w-full"> |
| 23 | <Layout allSections={allSections}>{children}</Layout> |
| 24 | </div> |
| 25 | </div> |
| 26 | ) |
| 27 | } |
nothing calls this directly
no outgoing calls
no test coverage detected