This tutorial doesn’t work (strings are not in my language when changed in General in admin panel)
https://ghost.org/docs/api/v2/handlebars-themes/helpers/translate/
What am I missing? Got locales
dir and 2 files pl.json
and en.json
This tutorial doesn’t work (strings are not in my language when changed in General in admin panel)
https://ghost.org/docs/api/v2/handlebars-themes/helpers/translate/
What am I missing? Got locales
dir and 2 files pl.json
and en.json
Hi there. Which parts of your site are you trying to translate? Might be a good idea to check the formatting of the json inside pl.json
and en.json
just incase it’s invalid
Formatting and structure of those files are copied from the same doc link I provided (just translated in pl.json
).
I’m trying to translate for example “X min read” text, or “Latest posts” in footer
Ah right I see. In the theme did you replace those values with the translation equivalent? For example the reading time handlebars variable should be replaced to this:
{{reading_time minute=(t "1 min read") minutes=(t "% min read")}}
If so then I can try debugging it at my end
Oh, I think I get it now! The default texts and variables from system are not translatable by default and I have to switch each text like you provided above.
After doing what you said to do - it works perfectly.
Thank you very much for your time and support!
No problem! Really pleased this solved it for you