Problem
When I try to download a JSON file, all UTF-8 characters are converted to unicode (e.g. Commander des cr\u00e9dits). I would like to preserve UTF-8 and accentuated characters during export.
Answer
Accentuated characters are escaped because of the nature of JSON formats. Most of JSON decoding logic accepts both escaped and non-escaped text to obtain the same result. Therefore OneSky outputs the escaped version to avoid potential problems (e.g. unicode encoding issues) for some languages and frameworks.
There is no harm in using the escaped characters in the JSON file.
Comments
4 comments
I need unescaped version of the JSON output
Special characters like ä,ü,ö are valid in json, there is absolutely no need to replace them. It blows up the code and makes it less read- and searchable in a big translation file. At least this replacement should be optionally
This article is absolutely useless, it only explains why but not how to deal with the conversion, for example, we pull the translation file, and then what? any suggested bash scripts or commands to actually do the job? The problem is with the Chinese project management running this development over in North point, no one has a brain on their heads to consider the real users of the system.
Hello
Accentuated characters are escaped because of the nature of JSON formats. Most of JSON decoding logic accepts both escaped and non-escaped text to obtain the same result. Therefore OneSky outputs the escaped version to avoid potential problems (e.g. unicode encoding issues) for some languages and frameworks.
Dinar Chronicles Update
Please sign in to leave a comment.