-
If I have a json
How do I convert Expected
With the expected output of
I can write my own function that escapes the quotes but wondering if there was some function native to the lib that did that already |
Beta Was this translation helpful? Give feedback.
Answered by
nlohmann
Dec 31, 2023
Replies: 1 comment 5 replies
-
Use dump: https://json.nlohmann.me/api/basic_json/#serialization-dumping |
Beta Was this translation helpful? Give feedback.
5 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Try
std::cout << json(j.dump()).dump() << std::endl;
May I ask why you need such an escaped string?