Liking cljdoc? Tell your friends :D
Clojure only.

clarktown.core


renderclj

(render markdown)
(render markdown given-parsers)
(render markdown given-parsers given-correctors)

Renders the given markdown into a consumable HTML form. Optionally, a second argument can be passed that is made out of a vector of parsers.

A parser is a map that consists of two things;

  • A matcher (optional) , which returns a truthy or falsey value
  • Renderers, which will be run on the a block when matcher returns true. There can be any number of renderers. Each renderer must return a string.

Each matcher, and each renderer have to be a function that take a single argument, which is a given Markdown block.

An example parser:

{:matcher (fn [block] ...)
 :renderers [(fn [block] ...) (fn [block] ...)]}
Renders the given `markdown` into a consumable HTML form. Optionally,
a second argument can be passed that is made out of a vector of parsers.

A parser is a map that consists of two things;
- A matcher (optional) , which returns a truthy or falsey value
- Renderers, which will be run on the a block when matcher returns true.
  There can be any number of renderers. Each renderer must return a string.

Each matcher, and each renderer have to be a function that take a single
argument, which is a given Markdown block.

An example parser:
```clojure
{:matcher (fn [block] ...)
 :renderers [(fn [block] ...) (fn [block] ...)]}
```
sourceraw docstring

cljdoc is a website building & hosting documentation for Clojure/Script libraries

× close