From cefb46dbddf0d19539c6fdfa13b9cfe5c92a661b Mon Sep 17 00:00:00 2001 From: Nafees Nazik <84864519+G3root@users.noreply.github.com> Date: Wed, 14 Sep 2022 00:37:10 +0530 Subject: [PATCH] fix: add translation in getServerSideProps (#4390) --- apps/web/pages/getting-started/[[...step]].tsx | 2 ++ 1 file changed, 2 insertions(+) diff --git a/apps/web/pages/getting-started/[[...step]].tsx b/apps/web/pages/getting-started/[[...step]].tsx index 08bd211b0d..1c8a791a43 100644 --- a/apps/web/pages/getting-started/[[...step]].tsx +++ b/apps/web/pages/getting-started/[[...step]].tsx @@ -1,4 +1,5 @@ import { GetServerSidePropsContext } from "next"; +import { serverSideTranslations } from "next-i18next/serverSideTranslations"; import Head from "next/head"; import { useRouter } from "next/router"; import { z } from "zod"; @@ -180,6 +181,7 @@ export const getServerSideProps = async (context: GetServerSidePropsContext) => return { props: { + ...(await serverSideTranslations(context.locale ?? "", ["common"])), user: { ...user, emailMd5: crypto.createHash("md5").update(user.email).digest("hex"),