21 releases (4 breaking)

✓ Uses Rust 2018 edition

0.6.4 Feb 26, 2020
0.6.3 Dec 26, 2019
0.5.2 Dec 13, 2019
0.5.1 Nov 26, 2019
0.4.1 Jul 2, 2019

#70 in Parser implementations

Download history 537/week @ 2020-03-09 410/week @ 2020-03-16 389/week @ 2020-03-23 285/week @ 2020-03-30 499/week @ 2020-04-06 641/week @ 2020-04-13 213/week @ 2020-04-20 246/week @ 2020-04-27 290/week @ 2020-05-04 258/week @ 2020-05-11 320/week @ 2020-05-18 325/week @ 2020-05-25 409/week @ 2020-06-01 405/week @ 2020-06-08 321/week @ 2020-06-15 510/week @ 2020-06-22

2,253 downloads per month
Used in 10 crates (4 directly)

MIT license

72KB
2K SLoC

MIT Latest Version docs Chat on Miaou

A simple, non universal purpose, markdown parser.

If you're looking for a Markdown parser, this one is probably not the one you want:

Minimad can be used on its own but is first designed for the termimad lib, which displays static and dynamic markdown snippets on a terminal without mixing the skin with the code. Minimad sports a line-oriented flat structure (i.e. not a tree) which might not suit your needs.

If you still think you might use Minimad directly (not through Temimad), you may contact me on Miaou for advice.

Usage

[dependencies]
minimad = "0.5"
assert_eq!(
    Line::from("## a header with some **bold**!"),
    Line::new_header(
        2,
        vec![
            Compound::raw_str("a header with some "),
            Compound::raw_str("bold").bold(),
            Compound::raw_str("!"),
        ]
    )
);

assert_eq!(
    Line::from("Hello ~~wolrd~~ **World**. *Code*: `sqrt(π/2)`"),
    Line::new_paragraph(vec![
        Compound::raw_str("Hello "),
        Compound::raw_str("wolrd").strikeout(),
        Compound::raw_str(" "),
        Compound::raw_str("World").bold(),
        Compound::raw_str(". "),
        Compound::raw_str("Code").italic(),
        Compound::raw_str(": "),
        Compound::raw_str("sqrt(π/2)").code(),
    ])
);

Dependencies

~13KB