Why is TOML.stringify()
output different for equivalent JSON input?
#27
-
How is j-toml "remembering" the format of the original TOML? How can I force j-toml to use a certain format for object literals that are added to the JSON? More details: https://stackoverflow.com/q/76288348/117030 |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
This library use |
Beta Was this translation helpful? Give feedback.
This library use
WeakMap
internal to remember object formats parsed by same library. For objects fromJSON.parse
or other way created, you may mark each object by helper functions provided by the library, because I didn't find a better way to know what coder want.See details in docs: https://github.com/LongTengDao/j-toml/tree/master/docs/English#tomlsection-tomlinline-tomlmultiline-tomlmultilinearray-tomlmultilinebasic-tomlbasic-tomlliteral-tomlcommentfor-tomlcommentforthis-tomlissection-tomlisinline