How can I beautify JSON with C#? I want to print the result in a TextBox control.
Is it possible to use JavaScriptSerializer for this, or should I use JSON.net? Un
Bit late to this party, but you can beautify (or minify) Json without deserialization using json.NET:
JToken parsedJson = JToken.Parse(jsonString); var beautified = parsedJson.ToString(Formatting.Indented); var minified = parsedJson.ToString(Formatting.None);