Skip to content

Commit

Permalink
implement JSON3 for HasFields
Browse files Browse the repository at this point in the history
  • Loading branch information
hhaensel committed Jan 14, 2022
1 parent 1e718ba commit 1bcda7b
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/json3.jl
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,5 @@ const StructTypes = JSON3.StructTypes
StructTypes.StructType(::Type{<:PlotlyBase.Plot}) = JSON3.RawType()
JSON3.rawbytes(plot::PlotlyBase.Plot) = codeunits(JSON.json(plot))

StructTypes.StructType(::Type{<:PlotlyBase.AbstractTrace}) = JSON3.RawType()
JSON3.rawbytes(trace::PlotlyBase.AbstractTrace) = codeunits(JSON.json(trace))

StructTypes.StructType(::Type{<:AbstractLayout}) = JSON3.RawType()
JSON3.rawbytes(layout::AbstractLayout) = codeunits(JSON.json(layout))
StructTypes.StructType(::Type{<:HasFields}) = JSON3.RawType()
JSON3.rawbytes(x::HasFields) = codeunits(JSON.json(x))

0 comments on commit 1bcda7b

Please sign in to comment.