Add option.go

This commit is contained in:
Masaaki Goshima 2020-09-16 18:23:43 +09:00
parent e1240f02fb
commit 40448a1cfe
1 changed files with 10 additions and 0 deletions

10
option.go Normal file
View File

@ -0,0 +1,10 @@
package json
type EncodeOption func(*Encoder) error
func UnorderedMap() EncodeOption {
return func(e *Encoder) error {
e.unorderedMap = true
return nil
}
}