ascetic-0.0.0.4: Generic markup builder.

Safe HaskellNone
LanguageHaskell98

Text.Ascetic

Description

Ascetic

Text/Ascetic.hs

Data structure, combinators, and functions for assembling data and emitting files in any XML-like or HTML-like markup language (consisting of tags, elements, attributes, declarations, and ASCII text content). Trade-offs are made in favor of simplicity and concision of constructors and combinators.

Synopsis

Documentation

type Content = String Source

Data type for simple markup trees and class for data types that can be converted into it.

data Ascetic Source

Instances

Eq Ascetic 
Show Ascetic

Default rendering uses "min" for HTML whitespace fidelity.

class ToAscetic a where Source

Type class for data structures that can be converted into the Ascetic representation.

Methods

ascetic :: a -> Ascetic Source

ascii :: Ascetic -> Content Source

Conversion to ASCII string (with indentation for legibility).

minified :: Ascetic -> Content Source

Conversion to an ASCII string that has no extra indentation or newlines for legibility.