23 lines
264 B
Julia
23 lines
264 B
Julia
using JSON
|
|
|
|
d = Dict(
|
|
"name"=>"ton",
|
|
"age"=> 20,
|
|
"metadata" => Dict(
|
|
"height"=> 155,
|
|
"wife"=> "jane"
|
|
)
|
|
)
|
|
|
|
json_str = JSON.json(d)
|
|
json_str_bytes = Vector{UInt8}(json_str)
|
|
json_str_2 = String(json_str_bytes)
|
|
json_obj = JSON.parse(json_str_2)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|