encoder
Values
pub fn glee_create_json_object(
key: String,
value: String,
) -> String
Create a simple JSON object with a single key-value pair
pub fn glee_create_json_object_from_pairs(
pairs: List(#(String, String)),
) -> String
Create a JSON object from multiple key-value pairs
pub fn glee_encode_bool(value: Bool) -> String
Encode a boolean value into a JSON string
pub fn glee_encode_float(value: Float) -> String
Encode a float value into a JSON string
pub fn glee_encode_int(value: Int) -> String
Encode an int value into a JSON string
pub fn glee_encode_list(values: List(String)) -> String
Encode a list of values into a JSON array string
pub fn glee_encode_object(
values: dict.Dict(String, String),
) -> String
Encode a map of string keys and string values into a JSON object string
pub fn glee_encode_string(value: String) -> String
Encode a string value into a JSON string
pub fn glee_parse_json_bool(
json: String,
field: String,
) -> Result(Bool, String)
Parse a JSON string and return the boolean value of a given field.