-
Notifications
You must be signed in to change notification settings - Fork 96
Lf 4950 translations break on page reload when offline i18n #4008
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: integration
Are you sure you want to change the base?
Lf 4950 translations break on page reload when offline i18n #4008
Conversation
…load-when-offline-i18n
| queryStringParams: { v: APP_VERSION }, | ||
| backends: [ | ||
| HttpBackend, | ||
| resourcesToBackend((lng, ns) => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the core change that should create desired behaviour
| react: { | ||
| useSuspense: true, | ||
| }, | ||
| ns: ['crop', 'expense', 'task', 'market_directory_info'], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These are loaded on init... which now that there is a fallback available... the buildTransactions tests have mixed translation loaded state. I am thinking it would be ideal to not load any translations on init.. or all of them.
Description
Sorry for delay pnpm build caught some type errors that pre-commit did not, rebase did not work this time either.
Changes since a few months ago are only related to TFunction typings and reinstalling packages.
There might also be a bad merge too or something since api tests are failing... if you could still check to translations though.Legit test failure the buildTransactions test is not pure.Notes:
xhr-backendtohttp-backendJira link: LF-4950
Type of change
How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce. Please also list any relevant details for your test configuration
Passes test case
UI components visually reviewed on desktop view
UI components visually reviewed on mobile view
Other (please explain):
pnpm run buildandpnpm run previewand using the offline radio button in service workers area of devtools to simulate the bug.I also saw that two of each language file was downloaded on my branch:
Checklist:
pnpm i18nto help with this)