fmx:macro

Freemarker equivalent: https://freemarker.apache.org/docs/ref_directive_macro.html

fmx:macro only exists as a dedicated xml element.It allows to define macros using an XML syntax.

Options

 

Note that attribute values aren't honored in this case (for now as it might change in the future).

Dedicated XML element

<fmx:macro fmx:name="todo" a="" b="'c'">
    <p>BEGIN</p>
    <fmx:nested />
    <p>END</p>
</fmx:macro>
[#macro todo a b]
    <p>BEGIN</p>
    [#nested ]
    <p>END</p>
[/#macro]