#Markdown parser written in Clojure
A markdown parser which compiles to both Clojure and ClojureScript.
boynton: Fixed some code block handling to be more consistent with multimarkdown. These are bug fixes for me, YMMV.
Leiningen
[boynton/markdown-clj "0.9.8"]
Maven
<dependency>
<groupId>markdown-clj</groupId>
<artifactId>markdown-clj</artifactId>
<version>0.9.8</version>
</dependency>
To build the Clojure jar
lein install
To compile the ClojureScript portion
lein cljsbuild once
Blockquote, Bold, Emphasis, Heading, Italics, Line, Paragraph, Strikethrough
Code Block, Indented Code, Inline Code
the number of hashes indicates the level of the heading
#Heading
##Sub-heading
###Sub-sub-heading
***
* * *
*****
- - -
*foo*
_foo_
**foo**
__foo__
>This is a blockquote
with some content
>this is another blockquote
This is a paragraph, it's
split into separate lines.
This is another paragraph.
indenting an item makes it into a sublist of the item above it, ordered and unordered lists can be nested within one another
* Foo
* Bar
* Baz
* foo
* bar
* baz
1. foo
2. bar
* fuzz
* blah
* blue
* brass
1. Foo
2. Bar
3. Baz
Here's some code `x + y = z` that's inlined.
Using three backquotes indicates a start of a code block, the next three backquotes ends the code block section. Optionally, the language name can be put after the backquotes to produce a tag compatible with the Syntax Highlighter, eg:
```clojure
(defn foo [bar] "baz")
```
indenting by at least 4 spaces creates a code block
some
code
here
note: XML is escaped in code sections
~~foo~~
a^2 + b^2 = c^2
[github](http://github.com)
![Alt text](http://server/path/to/img.jpg)
![Alt text](/path/to/img.jpg "Optional Title")
Copyright (C) 2012 Yogthos
Distributed under the Eclipse Public License, the same as Clojure.