I have some JSON data with UTF-8 encoded sequences which look like:
[{
"name": "Bj\u00c3\u00b6rn XYZe\u00c3\u009fle",
"comment": "text & text"
},
{
"name": "Simona XYZ",
"comment": "bla citizens\u00e2\u0080\u0099 autonomy and text."
}
]
In Hugo, I show this data with just {{ .name }}
.
The problem: It doesn’t recode these UTF-8 sequences but shows them like this:
Björn XYZieÃle
bla citizensâ autonomy and text
Obviously, I lack a decoding function. I already tried safeHTML, safeJS or htmlUnescape. What can I do except changing the input data?