I just nearly embarrassed myself by adding an issue to the Hugo repo proposing a default value for translation tags. But as always the solution is already baked in.
My thought was: normally when developing something you add all the language right there in the template files (looking at WordPress for instance) and now with Hugo we need to add an i18n/en.toml
and reference the values in there in the template. Which basically makes every location where text is printed a double-work, once in the layout and once in the language file.
But no: default
to the rescue.
{{ i18n "some_button_title" | default "My great and click-inducing default button title" }}
Thinking this further, this might be a perfect way to parse out all translation keys + values for the default language programmatically.