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
When I want to use Persian Language on my page, it requires me to toggle page direction to "rtl". I am using pages router and I tried a couple tricks people used on their app router using projects, like this one:
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
-
When I want to use Persian Language on my page, it requires me to toggle page direction to "rtl". I am using pages router and I tried a couple tricks people used on their app router using projects, like this one:
As you can see in the code, a
getLocale
function is being used to determine the locale user is reading. This seems right, but it gives this error:Error: `getLocale` is not supported in Client Components.
This is because I'm using page router and I've implemented this in the
_document.js
file.Any idea what should I do instead?
Beta Was this translation helpful? Give feedback.
All reactions