using next-translate in siteMetadata #669
Unanswered
vahidtakro
asked this question in
Q&A
Replies: 1 comment
-
@vahidtakro Ideally, the siteMetadata should be a namespace ( return <div>siteMetadata.comment.provider</div> you can do this: const { t } = useTranslation('siteMetadata') // which namespace
// ...
return <div>t('comment.provider')</div> |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
hello, i'm getting my pages main info from a file called siteMetadata, how can I use next-translate to translate the value of each string in the file? this is the file:
Beta Was this translation helpful? Give feedback.
All reactions