Skip to content
A fork of the golang encoding/json package to support ordered JSON decoding/encoding
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
testdata
LICENSE
README.md
bench_test.go
decode.go encoding/json: Optionally preserve the key order of JSON objects Jun 21, 2017
decode_test.go encoding/json: Optionally preserve the key order of JSON objects Jun 21, 2017
encode.go encoding/json: Optionally preserve the key order of JSON objects Jun 21, 2017
encode_test.go encoding/json: Optionally preserve the key order of JSON objects Jun 21, 2017
example_marshaling_test.go
example_test.go
fold.go
fold_test.go
indent.go
number_test.go
scanner.go encoding/json: add Valid for checking validity of input bytes Feb 7, 2017
scanner_test.go
stream.go
stream_test.go
tables.go
tagkey_test.go encoding/json: explicitly document and test "-" key tag Oct 6, 2016
tags.go
tags_test.go

README.md

go-ordered-json

There are some legacy/stupid applications[1] that you need to interoperate with, and they for whatever reason require that the JSON you're using is ordered in a particular way (contrary to the JSON specifications).

Unfortunately, the golang authors are not willing to support such a broken use case, so on their advice this is a fork of the golang encoding/json package, with the ordered JSON support originating with a patch from Peter Waldschmidt.

If you can, you should avoid using this package. However, if you can't avoid it, then you are welcome to. Provided under the MIT license, just like golang.

Known broken applications

You can’t perform that action at this time.