This node module unify the interface to use parsers. It's a light (simplified) implementation of parsers for HonKit:
| Parser | Repository |
|---|---|
| Markdown | honkit/markdown-legacy |
| AsciiDoc | honkit/asciidoc |
This module can be used in node.js
npm install @honkit/light-parsers
import honkitParsers from '@honkit/light-parsers';var parser = gitbookParsers.getForFile("FILE.md");Parse the summary:
parser.summary("* [An entry](./test.md)")
.then(function(summary) {
});Parse the glossary:
parser.glossary("...")
.then(function(glossary) {
});Parse the languages index:
parser.langs("...")
.then(function(languages) {
});Parse a page to html:
parser.page("...")
.then(function(sections) {
});