Replies: 1 comment 1 reply
-
If you use a splat route it should still load i18next since that's configured in entry.client and entry.server, and root is working. The splat route is the best way to do it, I recommend considering the root error boundary for 500 errors, errors where everything crashed and is down and in that case you don't even know how to correctly translate the errors (e.g. if root loader failed you don't know the user locale) |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
When the user enters a wrong URL, Remix throws the
ErrorBoundary
component fromroot.tsx
without running the root's loader. I can use a splat route as described here to run the loader but the i18next context will still be missing. Therefore, theErrorBoundary
component cannot show translations for 404 errors.What is the recommended approach to show a translated 404 errors in Remix?
Beta Was this translation helpful? Give feedback.
All reactions