mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2024-11-21 19:42:14 +00:00
GP-0: Adding support for footnotes
This commit is contained in:
parent
66068da147
commit
13f3a70334
@ -20,4 +20,5 @@ eclipse.project.name = '_MarkdownSupport'
|
||||
dependencies {
|
||||
implementation 'org.commonmark:commonmark:0.23.0'
|
||||
implementation 'org.commonmark:commonmark-ext-heading-anchor:0.23.0'
|
||||
implementation 'org.commonmark:commonmark-ext-footnotes:0.23.0'
|
||||
}
|
||||
|
@ -20,6 +20,7 @@ import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
import org.commonmark.Extension;
|
||||
import org.commonmark.ext.footnotes.FootnotesExtension;
|
||||
import org.commonmark.ext.heading.anchor.HeadingAnchorExtension;
|
||||
import org.commonmark.node.Link;
|
||||
import org.commonmark.node.Node;
|
||||
@ -49,8 +50,9 @@ public class MarkdownToHtml {
|
||||
throw new Exception("First argument doesn't not end with .md");
|
||||
}
|
||||
|
||||
// Setup the CommonMark Library with the needed "anchor extension" library
|
||||
List<Extension> extensions = List.of(HeadingAnchorExtension.create());
|
||||
// Setup the CommonMark Library with the needed extension libraries
|
||||
List<Extension> extensions =
|
||||
List.of(HeadingAnchorExtension.create(), FootnotesExtension.create());
|
||||
Parser parser = Parser.builder().extensions(extensions).build();
|
||||
HtmlRenderer renderer = HtmlRenderer.builder()
|
||||
.extensions(extensions)
|
||||
|
Loading…
Reference in New Issue
Block a user