Files
iddaai-fe/src/app/[locale]/(site)/teams/[id]/page.tsx
T
fahricansecer b2ccc98226
Deploy Iddaai Frontend / build-and-deploy (push) Successful in 2m41s
gg
2026-05-12 03:03:49 +03:00

36 lines
1.2 KiB
TypeScript

import { getTranslations } from "next-intl/server";
import TeamDetailContent from "@/components/teams/team-detail-content";
import { Metadata } from "next";
export async function generateMetadata(props: {
params: Promise<{ locale: string }>;
}): Promise<Metadata> {
const params = await props.params;
const { locale } = params;
const t = await getTranslations({ locale, namespace: "seo" });
const siteUrl = process.env.NEXT_PUBLIC_APP_URL || "https://iddaai.com";
// Next.js parses route variables automatically, but for canonical we'll just use a clean relative base if available,
// or let next.js construct it implicitly from metadataBase if not explicitly specified.
// We'll set alternates just for languages based on current path segment as a best effort
const pathSegment = "teams/[id]";
return {
title: t("teams.title"),
description: t("teams.description"),
alternates: {
canonical: `${siteUrl}/${locale}/${pathSegment}`,
languages: {
en: `${siteUrl}/en/${pathSegment}`,
tr: `${siteUrl}/tr/${pathSegment}`,
},
},
};
}
export default function TeamDetailPage() {
return <TeamDetailContent />;
}