Encodes value. Output is compact unless pretty (two-space indent). The result comes from
context.allocator.
- pretty: indents with two spaces and puts members on their own lines.
to_json :: (value: $T, pretty := false) -> string
Encodes value. Output is compact unless pretty (two-space indent). The result comes from
context.allocator.
Parameters
- value: $T
- pretty := false
- indents with two spaces and puts members on their own lines.
Returns
- string