Universal JSON AST datastructure.
This library provides only a data-type representing the JSON value tree. It is intended to be used as a shared data-type by all kinds of JSON libraries. Same as we have the "xml-types" package for libraries dealing with XML.
Now, since the "aeson" Value
has been serving this purpose for years, we've intentionally made this type representationally identical to it, making it possible to convert between them at 0 runtime cost. This means that we can use those types interchangeably, making it possible to gradually migrate.
Why displace the "aeson" Value
?
To boost the competition between JSON libraries. Instead of nudging the community to implement its ideas by patching "aeson". After all, competition is the driving force of evolution and hence progress.
Due to so much patching already happening to "aeson", its loss of focus, some questionable design and strive for backwards compatibility, it's becoming bloated. IOW, it's trying to be "everything JSON" but with no careful design or plan and it's tied by its past. With these restrictions it's impossible for "aeson" to ever become a polished library.