Support conditional content in emails, i.e. content that only shows if a condition is met.
For example, content that is only inserted if an invoice has attached files.
How it could work in an email templates:
====================
Your latest invoice is available online:
@DirectInvoiceLink@
Invoice #: @InvoiceNumber@
Total Amount: @InvoiceTotalAmount@
{% if @AttachedFileList@ %}
In addition, these spreadsheets provide itemized breakdown of our charges:
@AttachedFileList@
{% endif %}
With many thanks,
If the token that follows “if” evaluates to an empty string, e.g. there are no attached files, the content up to {% endif %} is ignored. Note that, to prevent weird paragraph spacing, it’s important to strictly honour the line spaces around and within the “if” clause.