Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- data Markdown
- = ThematicBreak
- | Paragraph [Markdown]
- | BlockQuote [Markdown]
- | CodeBlock Text Text
- | Heading Int [Markdown]
- | OrderedList Int [[Markdown]]
- | UnorderedList [[Markdown]]
- | Txt Text
- | Linebreak
- | InlineCode Text
- | Italics [Markdown]
- | Strong [Markdown]
- | Strikethrough [Markdown]
- | Link [Markdown] Text
- | Image [Markdown] Text
- | Table (Maybe [[Markdown]]) [[[Markdown]]]
- toText :: [Markdown] -> Text
Documentation
Custom type for converting Docs into Markdown. I tried using the existing cmark-gfm library for this, but we have too many edge-cases for it to work well.
ThematicBreak | E.g. '---' |
Paragraph [Markdown] | |
BlockQuote [Markdown] | |
CodeBlock Text Text | |
Heading Int [Markdown] | |
OrderedList Int [[Markdown]] | |
UnorderedList [[Markdown]] | |
Txt Text | |
Linebreak | |
InlineCode Text | |
Italics [Markdown] | |
Strong [Markdown] | |
Strikethrough [Markdown] | |
Link [Markdown] Text | |
Image [Markdown] Text | |
Table (Maybe [[Markdown]]) [[[Markdown]]] |