EntityEncoder and EntityDecoder for jsoniter in http4s.
Get latest release:
libraryDependencies += "com.github.cornerman" %% "http4s-jsoniter" % "0.1.2"
We additonally publish snapshot releases for every commit.
Import the encoder and decoder using Array[Byte] for reading and writing with jsoniter:
import http4sJsoniter.ArrayEntityCodec._
Import the encoder and decoder based on java InputStream
and OutputStream
for reading and writing with jsoniter:
import http4sJsoniter.JavaIOStreamEntityCodec._
TODO: configuring ReaderConfig and WriterConfig
For a more generic approach based on chameleon that supports multiple serialization libraries, checkout the chameleon-http4s
package: https://github.com/cornerman/chameleon.