Open attalbialami opened 1 month ago
Hi @attalbialami,
I don't know the reason, it seems to possibly show the last compiled locale. However, you should always use LOCALE_ID
as it is explicitly set in server.ts
.
Sorry, I can't give you more information.
Hello @agarciar
I used your project to test Angular 17 with SSR. I added the following code to the
AppComponent
, then ranpnpm build
andpnpm serve:ssr:ssr-i18n-angular17
:When running the project in SSRand visiting the URL http://localhost:4000/en
In the browser console, I see:
And in the Express server log, I see:
My question is: Why is
$localize.locale
on the server set to "de" and different from the one in the browser, which is "en"? Normally, they both should be "en".Could you please provide some explanation for this discrepancy? Your help is much appreciated.
Thank you.