UtilJsonBeautifyJson Method

Beautifies the contents of a unbeautified JSON string.

Definition

Namespace: DevCase.Core.DataProcessing.Json
Assembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
public static string BeautifyJson(
	string json,
	string indentString = ""
)

Parameters

json  String
The source (unbeautified) JSON string.
indentString  String  (Optional)
The string used to write the indentation blank space.

By default the tabulation char is used, you can change this value to " " (four white spaces) or whatever.

Return Value

String
The resulting beautified JSON string.

Remarks

All credits goes to @Peter Long: http://stackoverflow.com/a/6237866/1248295

Example

This is a code example.
C#
No code example is currently available or this language may not be supported.

See Also