Skip to content

Instantly share code, notes, and snippets.

@szandrzej
Created December 19, 2023 13:45
Show Gist options
  • Save szandrzej/36494ef4b9fe384fe5abfdbae9fad050 to your computer and use it in GitHub Desktop.
Save szandrzej/36494ef4b9fe384fe5abfdbae9fad050 to your computer and use it in GitHub Desktop.
`useTranslations` is not callable within an async component.
export default function Home() {
const t = useTranslations('Home');
return (
<div className={clsx('hero min-h-screen', styles.background)}>
<div className="flex flex-col items-center">
<OxlaLogo className="mb-8 w-[400px]" />
<a
className="rounded-2xl bg-oxla-blue px-16 py-3 text-center text-lg transition-colors hover:text-gray-200"
href={routes.dashboard}
>
{t('enterDashboard')}
</a>
</div>
</div>
);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment