import type { Metadata } from "next"; import { Plus_Jakarta_Sans, JetBrains_Mono } from "next/font/google"; import { NextIntlClientProvider } from 'next-intl'; import { getMessages, setRequestLocale } from 'next-intl/server'; import { notFound } from 'next/navigation'; import Script from 'next/script'; import { routing } from '@/i18n/routing'; import { Navbar } from '@/components/Navbar'; import { Footer } from '@/components/Footer'; import "../globals.css"; const jakartaSans = Plus_Jakarta_Sans({ variable: "--font-sans", subsets: ["latin"], weight: ["300", "400", "500", "600", "700", "800"], }); const jetbrainsMono = JetBrains_Mono({ variable: "--font-mono", subsets: ["latin"], weight: ["400", "500", "600", "700"], }); const BASE_URL = 'https://ayrisai.xyz'; export const metadata: Metadata = { metadataBase: new URL(BASE_URL), title: { default: 'ayris.tech YouTube | Code & Resource Portal', template: '%s | ayris.tech YouTube', }, description: 'Official resource portal for the ayris.tech YouTube channel. Browse source code, lesson notes, cheatsheets, AI prompts, and project downloads for every tutorial.', keywords: [ 'Next.js', 'React', 'TypeScript', 'Tailwind CSS', 'Python', 'YouTube tutorial', 'source code', 'ayris.tech', 'web development', 'AI agents', 'Prisma', 'Docker', 'full-stack', ], authors: [{ name: 'ayris.tech', url: BASE_URL }], creator: 'ayris.tech', openGraph: { type: 'website', locale: 'en_US', url: BASE_URL, siteName: 'ayris.tech YouTube Portal', title: 'ayris.tech YouTube | Code & Resource Portal', description: 'Source code, lesson notes, cheatsheets, and project downloads for every ayris.tech YouTube tutorial.', images: [{ url: `${BASE_URL}/logo.jpeg`, width: 400, height: 400, alt: 'ayris.tech Logo' }], }, twitter: { card: 'summary_large_image', title: 'ayris.tech YouTube | Code & Resource Portal', description: 'Source code, cheatsheets, AI prompts and downloads for every ayris.tech tutorial.', images: [`${BASE_URL}/logo.jpeg`], }, robots: { index: true, follow: true, googleBot: { index: true, follow: true }, }, alternates: { canonical: BASE_URL, }, }; export function generateStaticParams() { return routing.locales.map((locale) => ({ locale })); } export default async function RootLayout({ children, params }: Readonly<{ children: React.ReactNode; params: Promise<{ locale: string }>; }>) { const { locale } = await params; if (!routing.locales.includes(locale as any)) { notFound(); } setRequestLocale(locale); const messages = await getMessages(); return (
{/* Organization JSON-LD */} {/* WebSite JSON-LD */}