public class HeadingAnchorExtension extends Object implements HtmlRenderer.HtmlRendererExtension
Create it with create() or builder() and then configure it on the
renderer builder (HtmlRenderer.Builder#extensions(Iterable)).
The heading text will be used to create the id. Multiple headings with the same text will result in appending a hyphen and number. For example:
# Heading
# Heading
will result in
<h1 id="heading">Heading</h1>
<h1 id="heading-1">Heading</h1>
| Modifier and Type | Class and Description |
|---|---|
static class |
HeadingAnchorExtension.Builder |
| Modifier and Type | Method and Description |
|---|---|
static HeadingAnchorExtension.Builder |
builder() |
static Extension |
create() |
void |
extend(HtmlRenderer.Builder rendererBuilder) |
public static Extension create()
public static HeadingAnchorExtension.Builder builder()
public void extend(HtmlRenderer.Builder rendererBuilder)
extend in interface HtmlRenderer.HtmlRendererExtensionCopyright © 2022. All rights reserved.