mirror of
https://github.com/vercel/commerce.git
synced 2025-07-23 04:36:49 +00:00
Iterated with translations
This commit is contained in:
@@ -1,15 +1,22 @@
|
||||
'use client';
|
||||
|
||||
import LocaleSwitcher from 'components/ui/locale-switcher';
|
||||
import LocaleSwitcher from 'components/ui/locale-switcher/locale-switcher';
|
||||
import { useTranslations } from 'next-intl';
|
||||
|
||||
interface PageProps {
|
||||
params: {
|
||||
locale: string
|
||||
}
|
||||
}
|
||||
|
||||
export default function Index() {
|
||||
export default function Index({params: {locale}} : PageProps) {
|
||||
|
||||
const t = useTranslations('Index');
|
||||
|
||||
return (
|
||||
<div>
|
||||
<h1>{t('title')}</h1>
|
||||
<LocaleSwitcher />
|
||||
<LocaleSwitcher currentLocale={locale} />
|
||||
</div>
|
||||
)
|
||||
}
|
Reference in New Issue
Block a user