| Safe Haskell | None |
|---|
Text.Sundown.Html.ByteString
Contents
Description
Warning: you should not need to use this module, if you're storing your text sanely. Use Text.Sundown.Html.String or Text.Sundown.Html.Text so that you won't have to worry about text encoding.
If you really want to use ByteStrings directly, make sure that they are UTF-8.
- renderHtml :: Extensions -> HtmlRenderMode -> Bool -> Maybe Int -> ByteString -> ByteString
- smartypants :: ByteString -> ByteString
- data Extensions = Extensions {}
- allExtensions :: Extensions
- noExtensions :: Extensions
- data HtmlRenderMode = HtmlRenderMode {
- htmlSkipHtml :: Bool
- htmlSkipStyle :: Bool
- htmlSkipImages :: Bool
- htmlSkipLinks :: Bool
- htmlExpandTabs :: Bool
- htmlSafelink :: Bool
- htmlToc :: Bool
- htmlHardWrap :: Bool
- htmlUseXhtml :: Bool
- htmlEscape :: Bool
- noHtmlModes :: HtmlRenderMode
- allHtmlModes :: HtmlRenderMode
Documentation
Arguments
| :: Extensions | |
| -> HtmlRenderMode | |
| -> Bool | If true, smartypant the output |
| -> Maybe Int | The maximum nesting of the HTML. If Nothing, a default value (16) will be used. |
| -> ByteString | |
| -> ByteString |
Parses a ByteString containing the markdown, returns the Html code.
smartypants :: ByteString -> ByteStringSource
Converts punctuation in Html entities, http://daringfireball.net/projects/smartypants/
Markdown extensions
data Extensions Source
A set of switches to enable or disable markdown features.
Constructors
| Extensions | |
Fields
| |
allExtensions :: ExtensionsSource
All Extensions enabled
noExtensions :: ExtensionsSource
All Extensions disabled
Html render modes
data HtmlRenderMode Source
Constructors
| HtmlRenderMode | |
Fields
| |
noHtmlModes :: HtmlRenderModeSource
All the HtmlRenderMode disabled
allHtmlModes :: HtmlRenderModeSource
All the HtmlRenderMode enabled