PDFMonkey Liquid tags

partial / include

The Liquid language supports such things as partials. That said, they are base on files. A PDFMonkey template not being a file, such a thing isn't possible. That's why we provide a partial tag.
Input
1
{% partial 'line-item' %}
2
<tr>
3
<td>{{product.name}}</td>
4
<td>{{product.unitPrice}}</td>
5
<td>{{product.quantity}}</td>
6
<td>{{product.totalPrice}}</td>
7
</tr>
8
{% endpartial %}
9
10
{% for lineItem in lineItems %}
11
{% include 'line-item', product: lineItem %}
12
{% endfor %}
Copied!
Copy link