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
I just want to add a library which allows me to detect the current locale and translate the responses I'm sending (controller code).
So what's the beast way to implement this? The node-i18n library seems to be a good candidate, but Loopback doesn't seem to support it, although it exports an express middleware.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
Hi!
I just want to add a library which allows me to detect the current locale and translate the responses I'm sending (controller code).
So what's the beast way to implement this? The node-i18n library seems to be a good candidate, but Loopback doesn't seem to support it, although it exports an express middleware.
I did this:
// Application.ts
However, Loopback throws an error on each request (TypeError: handler is not a function).
So is this library supported? If it isn't, what should I use to multi language support?
Thanks in advance!
Beta Was this translation helpful? Give feedback.
All reactions