Documentation
¶
Overview ¶
Package orderedobject allows you to decode JSON dicts while preserving order. It uses the standard MarshalJSON and UnmarshalJSON interface and is thus compatible with most json encoders/decoders.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type OrderedObject ¶
OrderedObject is a JSON dict that preserves order. Keys are strings, and values are generically typed V.
func (OrderedObject[V]) MarshalJSON ¶
func (o OrderedObject[V]) MarshalJSON() ([]byte, error)
func (*OrderedObject[V]) UnmarshalJSON ¶
func (o *OrderedObject[V]) UnmarshalJSON(b []byte) error
Click to show internal directories.
Click to hide internal directories.