hledger-lib-1.43.2: A library providing the core functionality of hledger
Safe HaskellNone
LanguageHaskell2010

Hledger.Write.Html

Description

HTML writing helpers. This module would ideally hide the details of which HTML library is used, but it doesn't yet.

Currently hledger-web uses blaze-html, but hledger CLI reports use lucid. lucid has a more usable API than blaze-html (https:/chrisdone.composts/lucid). lucid2's is even better. Unfortunately lucid* can not render multi-line or indented text. We want this so that humans can read and troubleshoot our HTML output. So a transition to blaze-html may be coming.

Synopsis

Documentation

toHtml :: forall (m :: Type -> Type). (ToHtml a, Monad m) => a -> HtmlT m () #

Convert to HTML, doing HTML escaping.

type Html = Html () Source #

formatRow :: Lines border => [Cell border Html] -> Html Source #

styledTableHtml :: Lines border => [[Cell border Html]] -> Html Source #

Export spreadsheet table data as HTML table. This is derived from https://hackage.haskell.org/package/classify-frog-0.2.4.3/src/src/Spreadsheet/Format.hs