github.com/abemedia/go-don@v0.2.2-0.20240329015135-be88e32bb73b/encoding/json/json.go (about) 1 // Package json provides encoding and decoding of JSON data. 2 package json 3 4 import ( 5 "github.com/abemedia/go-don/encoding" 6 "github.com/goccy/go-json" 7 ) 8 9 func init() { 10 mediaType := "application/json" 11 12 encoding.RegisterDecoder(json.Unmarshal, mediaType) 13 encoding.RegisterEncoder(json.Marshal, mediaType) 14 }