Overview
Tutorials
Bundle guides
Further reading
Reference
Miscellaneous utilities.
Note
Included in the base bundle.
Check if a route exists. Useful for optionally showing a link to a route.
{% if perform_route_exists('my_route') %} <a href="{{path('my_route')}}">Click here</a> {% endif %}
Print a DateTime object as a phrase relative to the current time, e.g. ‘2 days ago’ or ‘5 years from now’.
DateTime
<p>{{date()|perform_human_date}}</p>