Open vytas7 opened 2 years ago
I've sketched a prototype how this could look like: https://gist.github.com/vytas7/7224c6d552c6e01992dfd84c01a40063.
Most probably, we won't be willing to enable such a handler by default in the first incarnation (because that would be a breaking change for req
handlers; debatable for resp
handlers). We could either add an optional handler that is not installed by default (like MessagePackHandler
), or morph my gist into a docs recipe.
While both Docs and a handler not enabled by default would do the job, if there is any interest in supporting the text/plain handler in the long term, perhaps adding it as handler would enable more usage for it.
Although, if we aren't sure about how the handler should work for different charsets or its design (i.e. can be breaking change over next few releases) then we can add it as a docs recipe until we finalize the design of it.
Let's start with a recipe.
Note that recipes now need to be covered with unit tests as well.
As proposed by @maxking on Gitter: