mirror of
https://github.com/TheRealOwenRees/echecsfrance.git
synced 2026-07-22 20:16:57 +00:00
df3a73df88
add metadata, moving splitting client and server component when needed as metadata is not allowed in a client component reusable baseUrl set x-url header for use in canonical urls for each page remove hardcoded title tag remove user-scalable=no to pass a11y checks, since it is ignored anyway by browsers now LCP set as priority loading
28 lines
618 B
TypeScript
28 lines
618 B
TypeScript
import { Metadata } from "next";
|
|
|
|
import SignInClient from "@/app/[locale]/(main)/auth/sign-in/SignInClient";
|
|
import { baseUrl } from "@/constants";
|
|
|
|
export async function generateMetadata({
|
|
params: { locale },
|
|
}: {
|
|
params: { locale?: string };
|
|
}): Promise<Metadata> {
|
|
return {
|
|
alternates: {
|
|
canonical:
|
|
locale === "fr"
|
|
? `${baseUrl}/auth/sign-in`
|
|
: `${baseUrl}/${locale}/auth/sign-in`,
|
|
languages: {
|
|
fr: `${baseUrl}/auth/sign-in`,
|
|
en: `${baseUrl}/en/auth/sign-in`,
|
|
},
|
|
},
|
|
};
|
|
}
|
|
|
|
export default function SignIn() {
|
|
return <SignInClient />;
|
|
}
|