Email Filters
These filters are intended for formatting and localizing content in email templates. They help with currency formatting and retrieving translations, ensuring that emails are clear and localized for recipients. Use these filters to display prices and support multiple languages in transactional emails.
money
Rounds the given amount in currenct display currency.
Input
{{ 3.45234 | money }}
Output
3.45
money_in_smallest
Returns the given amount in the smallest currency unit.
Input
{{ 3.45234 | money_in_smallest }}
Output
345
money_with_currency
Returns the amount in current display currency rounded and formatted.
Input
{{ 3.45234 | money_with_currency }}
Output
3.45 €
t
Retrieve a translation with given key from the locale file for the active locale.
Input
{{ "add_to_cart" | t }}
{{ "sold_out" | t: title: product.title }}
Output
Add to cart
Product Jeans is sold out
Last updated on