Function: serializeJson

serializeJson<T>(input, options?): string

Serializes the given data to a JSON string. By default the JSON string is formatted with a 2 space indentation to be easy readable.

Type parameters

NameType
Textends object = object

Parameters

NameTypeDescription
inputTObject which should be serialized to JSON
options?JsonSerializeOptionsJSON serialize options

Returns

string

the formatted JSON representation of the object