fix: there can only ever be one root layout, and it should always contains html and body tags
This commit is contained in:
@@ -18,16 +18,19 @@ import GTMScript from "@/components/TrackingSDK/GTMScript"
|
||||
import RouterTracking from "@/components/TrackingSDK/RouterTracking"
|
||||
import { getIntl } from "@/i18n"
|
||||
import ServerIntlProvider from "@/i18n/Provider"
|
||||
import { setLang } from "@/i18n/serverContext"
|
||||
|
||||
import type { LangParams, LayoutArgs } from "@/types/params"
|
||||
|
||||
export default async function RootLayout({
|
||||
children,
|
||||
params,
|
||||
}: React.PropsWithChildren<LayoutArgs<LangParams>>) {
|
||||
setLang(params.lang)
|
||||
const { defaultLocale, locale, messages } = await getIntl()
|
||||
|
||||
return (
|
||||
<>
|
||||
<html lang={params.lang}>
|
||||
<head>
|
||||
<AdobeSDKScript />
|
||||
<GTMScript />
|
||||
@@ -58,6 +61,6 @@ export default async function RootLayout({
|
||||
</ServerIntlProvider>
|
||||
</SessionProvider>
|
||||
</body>
|
||||
</>
|
||||
</html>
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user