Implement Doc class for rendering data types on frontend
This is a bit of an opaque task, however I think it could straighten things up in our code.
We often use a Show
class to render things when serializing to JSON (or some other internal stuff) and, at the same time, rendering that to the frontend (see H.text $ show x
).
This is error-prone. Instead, we could use Show
for internal stuff and Doc
for the frontend rendering.