Signature | fromJSON(v string) (any, error)
+Name | Value |
---|
Signature | FromJSON(v string) (any, error)
|
{% tabs %}
@@ -111,7 +111,7 @@ The function converts a Go data structure into a JSON string, allowing the data
The function converts a Go data structure into a pretty-printed JSON string, formatting the output with indentation and line breaks for better readability.
-Name | Value |
---|
Signature | toPrettyJSON(v any) (string, error)
+Name | Value |
---|
Signature | ToPrettyJSON(v any) (string, error)
|
{% tabs %}
@@ -127,7 +127,7 @@ The function converts a Go data structure into a pretty-printed JSON string, for
The function converts a Go data structure into a JSON string without escaping HTML characters, preserving the raw content as it is.
-Name | Value |
---|
Signature | toRawJSON(v any) (string, error)
+Name | Value |
---|
Signature | ToRawJSON(v any) (string, error)
|
{% tabs %}
@@ -143,7 +143,7 @@ The function converts a Go data structure into a JSON string without escaping HT
The function deserializes a YAML string into a Go map, allowing the structured data from YAML to be used and manipulated within a Go program.
-Name | Value |
---|
Signature | fromYAML(v string) (any, error)
+Name | Value |
---|
Signature | FromYAML(v string) (any, error)
|
{% tabs %}
@@ -159,7 +159,7 @@ The function deserializes a YAML string into a Go map, allowing the structured d
The function serializes a Go data structure into a YAML string, converting the data into a format suitable for YAML representation.
-Name | Value |
---|
Signature | toYAML(v any) (string, error)
+Name | Value |
---|
Signature | ToYAML(v any) (string, error)
|
{% tabs %}
@@ -175,7 +175,7 @@ The function serializes a Go data structure into a YAML string, converting the d
The function serializes a Go data structure into a YAML string, converting the data into a format suitable for YAML representation. In addition to toYAML, toIndentYAML takes a parameter to define the indentation width in spaces.
-Name | Value |
---|
Signature | toIndentYAML(indent int, v any) (string, error)
+Name | Value |
---|
Signature | ToIndentYAML(indent int, v any) (string, error)
|
{% tabs %}
|
|
|
|
|
|