Apr 17, 2019 in Drupal 8

The following snippet makes you format a date field inside a twig file.

{% set date = content.field_job_expiration.value|date('U')|format_date('short') %}
<p>Expiration: {{ date }}</p>