Markdown.Transmutationist

Markdown transformations.

HTML

toHtml : Block -> Html msg

Transform a Markdown block into HTML.

This function uses the default options:

  • imageLoadingStrategy: eager, the browser default.
toHtmlWithOptions :
{ imageLoadingStrategy : LoadingStrategy
}
-> Block
-> Html msg

Transform a Markdown block into HTML, with options.

inlineToHtml : Inline -> Html msg

Transform an inline Markdown element into HTML.

This function uses the default options:

  • imageLoadingStrategy: eager, the browser default.
inlineToHtmlWithOptions :
{ imageLoadingStrategy : LoadingStrategy
}
-> Inline
-> Html msg

Transform an inline Markdown element into HTML, with options.

JSON

blockDecoder : Decoder Block
inlineDecoder : Decoder Inline
htmlDecoder : Decoder Html
toJson : Block -> Value
inlineToJson : Inline -> Value
htmlToJson : Html -> Value
blockType : Block -> String
inlineType : Inline -> String
htmlType : Html -> String

Loading Strategy

type LoadingStrategy
= Eager
| Lazy
loadingStrategyToString : LoadingStrategy -> String