added test seo
This commit is contained in:
@@ -2,11 +2,11 @@ import Welcome from '@/widgets/welcome/ui';
|
||||
import { Metadata } from 'next';
|
||||
|
||||
interface Props {
|
||||
params: { lang: 'uz' | 'ru' };
|
||||
params: { locale: 'uz' | 'ru' };
|
||||
}
|
||||
|
||||
export async function generateMetadata({ params }: Props): Promise<Metadata> {
|
||||
const { lang } = params;
|
||||
const { locale } = await params;
|
||||
|
||||
const titles = {
|
||||
uz: 'Bosh sahifa | Mahsulotlar do‘koni',
|
||||
@@ -24,28 +24,28 @@ export async function generateMetadata({ params }: Props): Promise<Metadata> {
|
||||
};
|
||||
|
||||
return {
|
||||
title: titles[lang],
|
||||
description: descriptions[lang],
|
||||
keywords: keywords[lang],
|
||||
title: titles[locale],
|
||||
description: descriptions[locale],
|
||||
keywords: keywords[locale],
|
||||
openGraph: {
|
||||
title: titles[lang],
|
||||
description: descriptions[lang],
|
||||
title: titles[locale],
|
||||
description: descriptions[locale],
|
||||
siteName: 'Mahsulotlar do‘koni',
|
||||
images: [
|
||||
{
|
||||
url: '/logos/logo.png',
|
||||
width: 1200,
|
||||
height: 1200,
|
||||
alt: titles[lang],
|
||||
alt: titles[locale],
|
||||
},
|
||||
],
|
||||
locale: lang === 'uz' ? 'uz_UZ' : 'ru_RU',
|
||||
locale: locale === 'uz' ? 'uz_UZ' : 'ru_RU',
|
||||
type: 'website',
|
||||
},
|
||||
twitter: {
|
||||
card: 'summary_large_image',
|
||||
title: titles[lang],
|
||||
description: descriptions[lang],
|
||||
title: titles[locale],
|
||||
description: descriptions[locale],
|
||||
images: ['/logos/logo.png'],
|
||||
},
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user