Closed janklostermann closed 6 years ago
I think single page with twig-based translations is best.
Half-implemented this in https://github.com/getgrav/grav-plugin-error/commit/2e7c157f19161aecbc5f6919a99daf8a44116cbc. The page title cannot be translated with a single page, not consistently across themes, as they do not usually translate the title. Might need to have multiple pages just for the title?
The header/page title issue should be resolved by #26 now...
Sorry this was done already
@rhukster what do you think, is this a viable way to add a translation? Having separate pages for separate languages?
Or maybe it's better to have
in the
error.md
page frontmatter, and add{{ "PLUGIN_ERROR.ERROR_MESSAGE"|t}}
in the page body.For the title however it's the theme job to translate it, e.g. Antimatter has
{{ header.title|e('html') }}
, should change to{{ header.title|e('html')|t }}