Closed shadoath closed 1 month ago
I'll move this to a discussion since it seems to be a rather special usage question.
As a side note, you can pass a locale
to getTranslations({locale, namespace: 'basic'})
if you need to use multiple locales in server-only code.
Is your feature request related to a problem? Please describe.
I'm working to make both
useTranslations
andcreateTranslator
have a matching typeI'm going outside the norm to use
createTranslator
server side via a global.Here is a smushed-together version of my code.
Describe the solution you'd like
I tried something like:
Which is the opposite of what I would expect as I provided no namespace.
Describe alternatives you've considered
I want to keep the type safety and not need to use an
any
type for the work.My current thought is to stop using
useTranslations