Skip to content

Twig filters

This plugin provides the following filters for use in Twig templates:

eventDateRange

Formats the value of an EventDate field, displaying the first and last dates along with the time range. See EventDateHelper::formatDateRange()

{{ entry.date|eventDateRange }}
{# Output: Jul 30 - Aug 28, 2026 · 10AM – 11AM #}

{{ entry.date|eventDateRange('longDate') }}
{# Output: July 30 - August 28, 2026 #}

You can display the repeat rule description using EventDate::getRepeatDescription().

eventDate

Formats a specific occurrence of an EventDate. See EventDateHelper::formatDate()

<ul>
    {% for occurrence in entry.date.occurrences %}
        <li>{{ occurrence|eventDate }}</li>
    {% endfor %}
</ul>
{# Output:
  <ul>
    <li>Jul 30, 2026 ⋅ 10AM – 11AM</li>
    <li>Jul 31, 2026 ⋅ 10AM – 11AM</li>
    <li>Aug 1, 2026 ⋅ 10AM – 11AM</li>
  </ul> #}

eventTitle

Renders an event title using the configured template. See EventRenderer

eventDescription

Renders an event description using the configured template. See EventRenderer

eventLocation

Renders an event location using the configured template. See EventRenderer