Function: tryParseJSON()
tryParseJSON(
value
:string
,reviver
?: (this
:object
,key
:string
,value
:unknown
) =>unknown
):object
|string
|number
|boolean
|null
Try parse a stringified JSON string.
Parameters
Parameter | Type | Description |
---|---|---|
value | string | The string to parse as JSON. |
reviver ? | (this : object , key : string , value : unknown ) => unknown | A function that transforms the results. This function is recursively called for each member of the object. |
Returns
object
| string
| number
| boolean
| null