| Haskell Hierarchical Libraries (xhtml package) | Source code | Contents | Index

Text.XHtml.Debug

Contents

Tree Displaying Combinators
Html Debugging Combinators

Description
This module contains functions for displaying HTML as a pretty tree.
Synopsis

data HtmlTree

= HtmlLeaf Html
| HtmlNode Html [HtmlTree] Html

treeHtml :: [String] -> HtmlTree -> Html
debugHtml :: HTML a => a -> Html

Tree Displaying Combinators
data HtmlTree

The basic idea is you render your structure in the form of this tree, and then use treeHtml to turn it into a Html object with the structure explicit.
Constructors

HtmlLeaf Html |
HtmlNode Html [HtmlTree] Html |

Instances

HTML HtmlTree

treeHtml :: [String] -> HtmlTree -> Html
Html Debugging Combinators
debugHtml :: HTML a => a -> Html
This uses the above tree rendering function, and displays the Html as a tree structure, allowing debugging of what is actually getting produced.
Produced by Haddock version 0.8