stringify

external fun stringify(value: JsAny?): String(source)

Converts a JavaScript value to a JavaScript Object Notation (JSON) string.

Parameters

value

A JavaScript value, usually an object or array, to be converted.


external fun stringify(value: JsAny?, replacer: Replacer?, space: String? = definedExternally): String(source)

Converts a JavaScript value to a JavaScript Object Notation (JSON) string.

Parameters

value

A JavaScript value, usually an object or array, to be converted.

replacer

A function that transforms the results.

space

Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.


external fun stringify(value: JsAny?, replacer: Replacer?, space: Int?): String(source)
external fun stringify(value: JsAny?, properties: ReadonlyArray<JsAny>, space: Int?): String(source)


external fun stringify(value: JsAny?, properties: ReadonlyArray<JsAny>?, space: String? = definedExternally): String(source)

Converts a JavaScript value to a JavaScript Object Notation (JSON) string.

Parameters

value

A JavaScript value, usually an object or array, to be converted.

properties

An array of strings and numbers that acts as an approved list for selecting the object properties that will be stringified.

space

Adds indentation, white space, and line break characters to the return-value JSON text to make it easier to read.