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
Currently, the default serialization produces "key" : "value" (note: two spaces)
and the compact one produces "key":"value" (note: no space)
I'd like to see a third option here that produces another commonly seen format (the most common one I'm seeing at least): "key": "value" (note: single space after the colon).
Sorry for the late response. While I do understand that there are different styles out there, I don't really see a reason to change it. Changing the style may just cause trouble for some people who may have stored files locally and saved a hash of the content to detect changes.
A setting would be possible but there are too many different potential ways how you could format it. The framework has already outgrown the initial idea of being "simple" ^^. So I don't want to introduce tons of formatting settings and special cases.
(For some context: we were seeing this as an issue with tools that modify the manifest.json directly, which introduced a lot of version control noise since SimpleJSON changed every ": " to " : ". We have fixed that locally in that tooling but I thought it might be a reasonable request to have more "external" control over formatting here.)
Oh, and I think compared to nearly every other JSON library on the planet SimpleJSON is, indeed, very simple, and thus awesome for many use cases :)
Currently, the default serialization produces
"key" : "value"
(note: two spaces)and the compact one produces
"key":"value"
(note: no space)I'd like to see a third option here that produces another commonly seen format (the most common one I'm seeing at least):
"key": "value"
(note: single space after the colon).SimpleJSON/SimpleJSON.cs
Line 1009 in 6fc5622
I'd be happy to make a PR but wanted to
"key": "value"
The text was updated successfully, but these errors were encountered: