You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In my local development environment, I've encountered a scenario where after authenticating, sometimes SSR briefly turns off and then back on again. When SSR turns off, this can result in language packs not loading properly. Strangely, I cannot seem to reproduce this on sandbox.dspace.org, but the behavior is consistent in my local environment.
Here's what I'm doing:
Running latest main code as of Jan 31 for both frontend & backend
Starting frontend in Production mode: npm run build:prod; npm run serve:ssr
Visiting the homepage
Immediately logging in as any user
After login, in the logs for server-side rendering (where you ran npm run serve:ssr), I'm seeing this when the login occurs:
Universal off, serving for direct client-side rendering (CSR)
GET /reload/1738353823478 200 1.632 ms - 751
GET /home 200 947.703 ms - -
(The message "Universal off" is only triggered when SSR is disabled while the "server.ts" code is run)
After login, the homepage will load up without any i18n translations. Here's an example of what the header looks like:
The issue appears to be with the ssr.paths setting. It MUST include the /reload/ path (which is triggered after login to perform a hard refresh). When /reload/ is added to the configuration, I no longer see this odd behavior.
Describe the bug
This issue is related to #3682.
In my local development environment, I've encountered a scenario where after authenticating, sometimes SSR briefly turns off and then back on again. When SSR turns off, this can result in language packs not loading properly. Strangely, I cannot seem to reproduce this on sandbox.dspace.org, but the behavior is consistent in my local environment.
Here's what I'm doing:
main
code as of Jan 31 for both frontend & backendnpm run build:prod; npm run serve:ssr
After login, in the logs for server-side rendering (where you ran
npm run serve:ssr
), I'm seeing this when the login occurs:(The message "Universal off" is only triggered when SSR is disabled while the "server.ts" code is run)
After login, the homepage will load up without any i18n translations. Here's an example of what the header looks like:
The issue appears to be with the
ssr.paths
setting. It MUST include the/reload/
path (which is triggered after login to perform a hard refresh). When/reload/
is added to the configuration, I no longer see this odd behavior.I'll submit a PR to all three branches shortly to fix this issue.
Related work
Related to #3682
The text was updated successfully, but these errors were encountered: