packages

markdown

0.1.0공식

CommonMark + GFM (tables, callouts, footnotes, heading anchors) to HTML

공개 · MIT OR Apache-2.0 · 의존성 0개

공식 패키지: use markdown::..;만 쓰면 첫 빌드가 추가합니다. 또는:

nabi add markdown

그다음 코드에서

use markdown::render;
deps: {
    "markdown": Dep::version("^0.1.0"),
},

CI packages.nabi-lang.org License: MIT OR Apache-2.0

A Nabi library that converts Markdown to HTML. It covers the main parts of CommonMark plus GitHub extensions (tables, strikethrough, callouts, footnotes, heading anchors), and renders the pages of docs.nabi-lang.org.

Add it

nabi add markdown

Needs Nabi 0.1 or later.

Usage

use markdown::render;

let doc = render("# Title\n\nBody *emphasis*\n");
println(doc.html);     // <h1 id="title">...Title</h1> ...
println(doc.title);    // Title

Use render_untrusted for Markdown of unknown origin, and pass Options to map link destinations or highlight code blocks. There is no highlighter dependency; pass one through Options.code (pairs well with nabi-syntax).

Docs

https://packages.nabi-lang.org/packages/markdown/latest/docs

License

Licensed under either of MIT or Apache-2.0, at your option.

README 출처: github.com/nabi-lang/markdown, 커밋 909d7ddd.