Skip to content

Go package for reading and writing JSON text sequences (application/json-seq) as defined in RFC 7464

License

Notifications You must be signed in to change notification settings

jmank88/jsonseq

Repository files navigation

jsonseq GoDoc Build Status Go Report Card

A Go package providing methods for reading and writing JSON text sequences (application/json-seq) as defined in RFC 7464 (https://tools.ietf.org/html/rfc7464).

Usage

_ = jsonseq.NewEncoder(os.Stdout).Encode("Test")
// �"Test"

_ = jsonseq.WriteRecord(os.Stdout, []byte(`{"id":2}`))
// �{"id":2}

var i interface{}
d := jsonseq.NewDecoder(strings.NewReader(`�{"id":1} �1234�1234 �true discarded junk`))
_ = d.Decode(&i)
fmt.Println(i)
// map[id:1]

See the GoDoc for more information and examples.

About

Go package for reading and writing JSON text sequences (application/json-seq) as defined in RFC 7464

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages