feat: add meta data (#105)
This commit is contained in:
@@ -1,4 +1,6 @@
|
||||
import { LocaleCodeType } from '@/types/locale';
|
||||
import { ProjectHome } from './ProjectHome';
|
||||
import { getTranslations } from 'next-intl/server';
|
||||
import { useTranslations } from 'next-intl';
|
||||
import { PriorityMessages } from '@/types/priority';
|
||||
import { TestTypeMessages } from '@/types/testType';
|
||||
@@ -14,6 +16,14 @@ export type HomeMessages = {
|
||||
byPriority: string;
|
||||
};
|
||||
|
||||
export async function generateMetadata({ params: { locale } }: { params: { locale: LocaleCodeType } }) {
|
||||
const t = await getTranslations({ locale, namespace: 'Home' });
|
||||
return {
|
||||
title: `${t('home')} | UnitTCMS`,
|
||||
robots: { index: false, follow: false },
|
||||
};
|
||||
}
|
||||
|
||||
export default function Page({ params }: { params: { projectId: string } }) {
|
||||
const t = useTranslations('Home');
|
||||
const messages = {
|
||||
|
||||
Reference in New Issue
Block a user