Json.stringify: how configure encoding.
See original GitHub issueval telemetryData = Json.stringify(
TelemetryData.serializer(),
TelemetryData(
"Русский язык ТЕСТ", // ← this have problem with encoding
LocalDateTime.now().toString(),
project.name,
TemporaryData.sourcesDirectory,
TemporaryData.editedFileDataList
)
)
after println(telemetryData)
i have {"user":"??????? ???? ????"...
library name | version |
---|---|
kotlinx serialization runtime | 0.11.0 |
kotlin serialization | 1.3.30 |
kotlin version | 1.3.30 |
Issue Analytics
- State:
- Created 4 years ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
JSON.stringify() to UTF-8 - javascript - Stack Overflow
So, yes, JSON.stringify() will return a string in whatever encoding your implementation uses for strings. If you were to find a way to...
Read more >JSON.stringify() - JavaScript - MDN Web Docs
The JSON.stringify() method converts a JavaScript value to a JSON string, ... Before this change, such strings could not be encoded in valid ......
Read more >Encoding JSON - Haxe - The Cross-platform Toolkit
Json.stringify static method to encode a Haxe value into a JSON string: class Main { static function main() { var o = {rating:...
Read more >How to decode and encode JSON Data in JavaScript
How to decode and encode JSON data in JavaScript. You will learn how to encode and decode JSON data in JavaScript with the...
Read more >JSON and the stringification oddities in JavaScript - Zhenghao
What we have discussed so far is the default behaviour of how JavaScript encodes values into JSON strings via JSON.stringify .
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
I doubt that this is a library problem, it’s rather your console/environment printing them incorrectly. Printing to file may help.
It incorrectly encoding caused “???”, but it also send to server \ save to file with “???”. but debugger show good result as need.
How do I solve the problem - I will describe the solution here. It would be not cultural to leave without leaving an answer 😃
Thanks, please mark it issue as
false problem
.UPD: Currently problem not solved, but most likely a problem with the coding console