diff --git a/option.go b/option.go new file mode 100644 index 0000000..b2414a7 --- /dev/null +++ b/option.go @@ -0,0 +1,10 @@ +package json + +type EncodeOption func(*Encoder) error + +func UnorderedMap() EncodeOption { + return func(e *Encoder) error { + e.unorderedMap = true + return nil + } +}