Footnotes
Preview Feature
This module is currently in preview. Request access to try it out.
Adding footnotes to documents using the docstencil-docx-pro module.
Adding the Module
OfficeTemplateOptions options = new OfficeTemplateOptions()
.withModule(new FootnoteModule());
val options = OfficeTemplateOptions()
.withModule(FootnoteModule())
Basic Syntax
Use $footnote to insert a footnote reference with its content:
This claim requires citation{insert $footnote("Source: Annual Report 2024")}*{end}.
The placeholder (*) becomes a footnote reference number, and the text appears at the bottom of the page.
Dynamic Content
Use variables for footnote text:
{insert $footnote(source.citation)}*{end}
Footnotes in Loops
Generate footnotes from data:
{for fact in facts}
{fact.statement}{insert $footnote(fact.source)}*{end}
{end}
Formatting Within Footnotes
Footnote text can include expressions:
{insert $footnote("See " + reference.title + ", page " + reference.page)}*{end}
Multiple Footnotes
Each footnote is automatically numbered:
First point{insert $footnote("First source")}*{end} and
second point{insert $footnote("Second source")}*{end}.
Produces footnotes numbered 1, 2, etc. at the page bottom.