MCPcopy Create free account
hub / github.com/CommandCodeAI/BaseAI / generateMetadata

Function generateMetadata

apps/baseai.dev/src/app/learn/layout.tsx:5–35  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

3import '@/styles/tailwind.css';
4
5export async function generateMetadata() {
6 const { frontmatter } = await getLearnBySlug({
7 slug: 'index',
8 section: 'learn',
9 });
10
11 return {
12 title: frontmatter?.title,
13 description: frontmatter?.description,
14 keywords: frontmatter?.tags,
15 openGraph: {
16 title: frontmatter?.title,
17 description: frontmatter?.description,
18 url: frontmatter?.url,
19 images: [
20 {
21 url: frontmatter?.imageUrl,
22 alt: frontmatter?.title
23 }
24 ]
25 },
26 twitter: {
27 title: frontmatter?.title,
28 description: frontmatter?.description,
29 image: frontmatter?.imageUrl
30 },
31 alternates: {
32 canonical: frontmatter?.url
33 }
34 };
35}
36
37export default async function RootLayout({
38 children

Callers

nothing calls this directly

Calls 1

getLearnBySlugFunction · 0.90

Tested by

no test coverage detected