aeson-match-qq-1.7.0: Declarative JSON matchers.
Safe HaskellSafe-Inferred
LanguageHaskell2010

Aeson.Match.QQ.Internal.AesonUtils

Synopsis

Documentation

toJSONE :: ToJSON x => x -> Value Source #

This is a round-about way to produce a Value from a ToJSON instance. it is written this way to avoid calling toJSON which might be undefined for some datatypes that only implement toEncoding.

It is defined in a separate module due to the TH stage restrictions as we need to lift toJSONE eventually.

pp :: Value -> Doc Source #

A super-basic re-implementation of aeson-pretty. This function attains 2 goals:

  • we avoid another dependency
  • it uses the same prettyprinter everything else uses, and thus it is easily integrated.