Elements are XML-like tags embedded inside a template that control how data is rendered beyond simple value injection. While merge fields ({!Object.FieldName}) output a raw value, elements handle repeating rows, conditional sections, images, rich text, barcodes, and more.
Elements are written directly in your template file. The Doctavian Add-in (Word, Excel) and Add-on (Google Docs, Sheets) let you insert them from a UI panel without writing the tags manually.
Not all elements are available in every template format. See the Elements Reference for the full format support matrix.
Every element supports a name parameter (required) and a hidden parameter (optional) that accepts an expression evaluating to true or false. When hidden is true, the element is suppressed from the output entirely.
<mdoc:text name="discountLine"
value="{!$concat('-', Invoice[0].DiscountPercent, '%')}"
hidden="{!$Invoice[0].DiscountPercent == 0}" />Parameters marked as supporting expressions accept {!$Expression} notation in addition to static values.