| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
CMarkGFM
- commonmarkToHtml :: [CMarkOption] -> [CMarkExtension] -> Text -> Text
- commonmarkToXml :: [CMarkOption] -> [CMarkExtension] -> Text -> Text
- commonmarkToMan :: [CMarkOption] -> [CMarkExtension] -> Maybe Int -> Text -> Text
- commonmarkToLaTeX :: [CMarkOption] -> [CMarkExtension] -> Maybe Int -> Text -> Text
- commonmarkToNode :: [CMarkOption] -> [CMarkExtension] -> Text -> Node
- registerPlugins :: IO ()
- nodeToHtml :: [CMarkOption] -> [CMarkExtension] -> Node -> Text
- nodeToXml :: [CMarkOption] -> Node -> Text
- nodeToMan :: [CMarkOption] -> Maybe Int -> Node -> Text
- nodeToLaTeX :: [CMarkOption] -> Maybe Int -> Node -> Text
- nodeToCommonmark :: [CMarkOption] -> Maybe Int -> Node -> Text
- optSourcePos :: CMarkOption
- optHardBreaks :: CMarkOption
- optSmart :: CMarkOption
- optSafe :: CMarkOption
- extStrikethrough :: CMarkExtension
- extTable :: CMarkExtension
- extAutolink :: CMarkExtension
- extTagfilter :: CMarkExtension
- data Node = Node (Maybe PosInfo) NodeType [Node]
- data NodeType
- = DOCUMENT
- | THEMATIC_BREAK
- | PARAGRAPH
- | BLOCK_QUOTE
- | HTML_BLOCK Text
- | CUSTOM_BLOCK OnEnter OnExit
- | CODE_BLOCK Info Text
- | HEADING Level
- | LIST ListAttributes
- | ITEM
- | TEXT Text
- | SOFTBREAK
- | LINEBREAK
- | HTML_INLINE Text
- | CUSTOM_INLINE OnEnter OnExit
- | CODE Text
- | EMPH
- | STRONG
- | LINK Url Title
- | IMAGE Url Title
- | STRIKETHROUGH
- | TABLE [TableCellAlignment]
- | TABLE_ROW
- | TABLE_CELL
- data PosInfo = PosInfo {}
- data DelimType
- data ListType
- data ListAttributes = ListAttributes {}
- type Url = Text
- type Title = Text
- type Level = Int
- type Info = Text
- data TableCellAlignment
- data CMarkOption
- data CMarkExtension
Documentation
commonmarkToHtml :: [CMarkOption] -> [CMarkExtension] -> Text -> Text Source #
Convert CommonMark formatted text to Html, using cmark's built-in renderer.
commonmarkToXml :: [CMarkOption] -> [CMarkExtension] -> Text -> Text Source #
Convert CommonMark formatted text to CommonMark XML, using cmark's built-in renderer.
commonmarkToMan :: [CMarkOption] -> [CMarkExtension] -> Maybe Int -> Text -> Text Source #
Convert CommonMark formatted text to groff man, using cmark's built-in renderer.
commonmarkToLaTeX :: [CMarkOption] -> [CMarkExtension] -> Maybe Int -> Text -> Text Source #
Convert CommonMark formatted text to latex, using cmark's built-in renderer.
commonmarkToNode :: [CMarkOption] -> [CMarkExtension] -> Text -> Node Source #
Convert CommonMark formatted text to a structured Node tree,
which can be transformed or rendered using Haskell code.
registerPlugins :: IO () Source #
Register core extensions. This should be done once at program start.
nodeToHtml :: [CMarkOption] -> [CMarkExtension] -> Node -> Text Source #
nodeToLaTeX :: [CMarkOption] -> Maybe Int -> Node -> Text Source #
nodeToCommonmark :: [CMarkOption] -> Maybe Int -> Node -> Text Source #
optSourcePos :: CMarkOption Source #
Include a data-sourcepos attribute on block elements.
optHardBreaks :: CMarkOption Source #
Render softbreak elements as hard line breaks.
optSmart :: CMarkOption Source #
Convert straight quotes to curly, --- to em-dash, -- to en-dash.
optSafe :: CMarkOption Source #
Suppress rendering of raw HTML and potentially dangerous URLs in links and images.
Constructors
| DOCUMENT | |
| THEMATIC_BREAK | |
| PARAGRAPH | |
| BLOCK_QUOTE | |
| HTML_BLOCK Text | |
| CUSTOM_BLOCK OnEnter OnExit | |
| CODE_BLOCK Info Text | |
| HEADING Level | |
| LIST ListAttributes | |
| ITEM | |
| TEXT Text | |
| SOFTBREAK | |
| LINEBREAK | |
| HTML_INLINE Text | |
| CUSTOM_INLINE OnEnter OnExit | |
| CODE Text | |
| EMPH | |
| STRONG | |
| LINK Url Title | |
| IMAGE Url Title | |
| STRIKETHROUGH | |
| TABLE [TableCellAlignment] | |
| TABLE_ROW | |
| TABLE_CELL |
Constructors
| PERIOD_DELIM | |
| PAREN_DELIM |
Constructors
| BULLET_LIST | |
| ORDERED_LIST |
data ListAttributes Source #
Constructors
| ListAttributes | |
data TableCellAlignment Source #
data CMarkOption Source #
data CMarkExtension Source #