updates to json.encode to address PR feedback
parent
de40dd131e
commit
e3f8173314
|
@ -18,13 +18,13 @@ import "json"
|
||||||
json.encode(v: "some value")
|
json.encode(v: "some value")
|
||||||
```
|
```
|
||||||
|
|
||||||
The function encodes [Flux types](/v2.0/reference/flux/language/types/) in the following manner:
|
This function encodes [Flux types](/v2.0/reference/flux/language/types/) as follows:
|
||||||
|
|
||||||
- It encodes `time` values using [RFC3339](https://tools.ietf.org/html/rfc3339).
|
- `time` values in [RFC3339](https://tools.ietf.org/html/rfc3339) format
|
||||||
- It encodes `duration` values in number of milliseconds since the epoch.
|
- `duration` values in number of milliseconds since the epoch
|
||||||
- It encodes `regexp` values as their string representation.
|
- `regexp` values as their string representation
|
||||||
- It encodes `bytes` values as base64-encoded strings.
|
- `bytes` values as base64-encoded strings
|
||||||
- It cannot encode `function` values and will produce an error.
|
- `function` values are not encoded and produce an error
|
||||||
|
|
||||||
## Parameters
|
## Parameters
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue