[Haskell-cafe] Generating valid html

Wojtek Narczyński wojtek at power.com.pl
Mon Nov 24 16:27:22 UTC 2014

On 19.11.2014 09:46, oleg at okmij.org wrote:
> Somewhat related is the HSXML library for generating valid XML and
> HTML. To be precise, the library is designed to express in the type
> system content model constraints such as: block-level elements like DIV
> are allowed only in the block-level context; one cannot put DIV within
> H1, for example. Some items may be polymorphic: for example, TITLE
> appears in HEAD, it can be an attribute and it can be an element. It
> can be rendered differently in each case. The same HSXML document may
> be rendered as HTML or XML (or something else entirely, e.g., PDF).
> http://okmij.org/ftp/Scheme/xml.html#typed-SXML
Very nice syntax, but I have yet to figure out how it works. BTW the 
error messages are "funny", as being discussed right now in another thread.


More information about the Haskell-Cafe mailing list