| |||||||||||||||||||||
| |||||||||||||||||||||
| |||||||||||||||||||||
Synopsis | |||||||||||||||||||||
Basic quasiquoters | |||||||||||||||||||||
hamlet :: QuasiQuoter | |||||||||||||||||||||
Calls hamletWithSettings with defaultHamletSettings. | |||||||||||||||||||||
xhamlet :: QuasiQuoter | |||||||||||||||||||||
Calls hamletWithSettings using XHTML 1.0 Strict settings. | |||||||||||||||||||||
hamletDebug :: QuasiQuoter | |||||||||||||||||||||
Calls hamletWithSettings with debugHamletSettings. | |||||||||||||||||||||
Load from external file | |||||||||||||||||||||
hamletFile :: FilePath -> Q Exp | |||||||||||||||||||||
Calls hamletFileWithSettings with defaultHamletSettings. | |||||||||||||||||||||
xhamletFile :: FilePath -> Q Exp | |||||||||||||||||||||
Calls hamletFileWithSettings using XHTML 1.0 Strict settings. | |||||||||||||||||||||
hamletFileDebug :: FilePath -> Q Exp | |||||||||||||||||||||
Customized settings | |||||||||||||||||||||
hamletWithSettings :: HamletSettings -> QuasiQuoter | |||||||||||||||||||||
A quasi-quoter that converts Hamlet syntax into a function of form: (url -> String) -> Html Please see accompanying documentation for a description of Hamlet syntax. | |||||||||||||||||||||
hamletFileWithSettings :: HamletSettings -> FilePath -> Q Exp | |||||||||||||||||||||
data HamletSettings | |||||||||||||||||||||
| |||||||||||||||||||||
defaultHamletSettings :: HamletSettings | |||||||||||||||||||||
Defaults settings: HTML5 doctype and HTML-style empty tags. | |||||||||||||||||||||
xhtmlHamletSettings :: HamletSettings | |||||||||||||||||||||
Datatypes | |||||||||||||||||||||
newtype Html | |||||||||||||||||||||
| |||||||||||||||||||||
type Hamlet url = (url -> [(String, String)] -> String) -> Html | |||||||||||||||||||||
An function generating an Html given a URL-rendering function. | |||||||||||||||||||||
Typeclass | |||||||||||||||||||||
class ToHtml a where | |||||||||||||||||||||
| |||||||||||||||||||||
class Monad (HamletMonad a) => HamletValue a where | |||||||||||||||||||||
| |||||||||||||||||||||
Construction | |||||||||||||||||||||
preEscapedString :: String -> Html | |||||||||||||||||||||
string :: String -> Html | |||||||||||||||||||||
unsafeByteString :: ByteString -> Html | |||||||||||||||||||||
cdata :: Html -> Html | |||||||||||||||||||||
Wrap an Html for embedding in an XML file. | |||||||||||||||||||||
Rendering | |||||||||||||||||||||
ByteString | |||||||||||||||||||||
renderHamlet :: (url -> [(String, String)] -> String) -> Hamlet url -> ByteString | |||||||||||||||||||||
Converts a Hamlet to lazy bytestring. | |||||||||||||||||||||
renderHtml :: Html -> ByteString | |||||||||||||||||||||
Text | |||||||||||||||||||||
renderHamletText :: (url -> [(String, String)] -> String) -> Hamlet url -> Text | |||||||||||||||||||||
renderHtmlText :: Html -> Text | |||||||||||||||||||||
Runtime Hamlet | |||||||||||||||||||||
data HamletRT | |||||||||||||||||||||
data HamletData url | |||||||||||||||||||||
| |||||||||||||||||||||
data HamletException | |||||||||||||||||||||
| |||||||||||||||||||||
parseHamletRT :: Failure HamletException m => HamletSettings -> String -> m HamletRT | |||||||||||||||||||||
renderHamletRT :: Failure HamletException m => HamletRT -> HamletMap url -> (url -> [(String, String)] -> String) -> m Html | |||||||||||||||||||||
Produced by Haddock version 2.6.0 |