File tree Expand file tree Collapse file tree 3 files changed +13
-12
lines changed Expand file tree Collapse file tree 3 files changed +13
-12
lines changed Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ interface LocaleLayoutProps {
2727}
2828
2929export function generateStaticParams ( ) {
30- return routing . locales . map ( ( locale ) => ( { locale} ) ) ;
30+ return routing . locales . map ( ( locale ) => ( { locale } ) ) ;
3131}
3232
3333export default async function LocaleLayout ( {
Original file line number Diff line number Diff line change @@ -2,20 +2,21 @@ import { getRequestConfig } from "next-intl/server";
22import { routing } from "./routing" ;
33
44export default getRequestConfig ( async ( { requestLocale } ) => {
5- // This typically corresponds to the `[locale]` segment
65 let locale = await requestLocale ;
76
8- // Ensure that a valid locale is used
97 if ( ! locale || ! routing . locales . includes ( locale as any ) ) {
108 locale = routing . defaultLocale ;
119 }
1210
13- if ( process . env . NODE_ENV === 'development' ) {
14- const res = await fetch ( `${ process . env . TOLGEE_API_URL } /v2/projects/${ process . env . TOLGEE_PROJECT_ID } /translations/${ locale } ` , {
15- headers : {
16- 'x-api-key' : `${ process . env . TOLGEE_API_KEY } ` ,
11+ if ( process . env . NODE_ENV === "development" ) {
12+ const res = await fetch (
13+ `${ process . env . TOLGEE_API_URL } /v2/projects/${ process . env . TOLGEE_PROJECT_ID } /translations/${ locale } ` ,
14+ {
15+ headers : {
16+ "x-api-key" : `${ process . env . TOLGEE_API_KEY } ` ,
17+ } ,
1718 } ,
18- } ) ;
19+ ) ;
1920 const data = await res . json ( ) ;
2021 const messages = data [ locale ] ;
2122
Original file line number Diff line number Diff line change 11const config = {
2- plugins : {
3- "@tailwindcss/postcss" : { } ,
4- } ,
2+ plugins : {
3+ "@tailwindcss/postcss" : { } ,
4+ } ,
55} ;
6- export default config ;
6+ export default config ;
You can’t perform that action at this time.
0 commit comments