You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The reason why I prefer to use YAML is the ability to use comments. So my question is :
Since JSON doesn't support comments, how can I serializeYml() with comments?
I know you can deserialize a YAML with comments to a JsonObject, but I guess you loose the comments.
I want to :
read a YAML file (with comments in it)
change the content
write back the YAML with the changes and the comments
The text was updated successfully, but these errors were encountered:
Keeping comments between editions seems impossible as they're implicitely dumped by the scanner.
The topic is still open, missing features are whitespace preservation and comment token/event handling.
Moreover, editing YAML without ArduinoJson requires a libyaml C++ wrapper with a real iterator and accessors.
Good news is pure-libyaml manipulation was on the roadmap of this project, so I can go halfway and integrate this C++ libyaml wrapper as a start, then see what happens to existing comments after editing the yaml.
Going any further will mean contributing the upstream libyaml project, and the test suite is really scary :)
[edit] libyaml-cpp didn't help, the problem is in yaml design and libyaml minimalism.
Hello,
The reason why I prefer to use YAML is the ability to use comments. So my question is :
Since JSON doesn't support comments, how can I serializeYml() with comments?
I know you can deserialize a YAML with comments to a JsonObject, but I guess you loose the comments.
I want to :
The text was updated successfully, but these errors were encountered: