> ## Documentation Index
> Fetch the complete documentation index at: https://reportana.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# For

When we have an array-type variable, such as tracking updates in `tracking_number.events`, we can use `for` to display each item of the array in an organized way.

*For example*, with `for`, we can show each tracking update with details like date, event type, location, and description:

```twig theme={null}
{% for event in tracking_number.events %} <br>

  {{ event.date|date("d/m/Y") }} <br>
  {{ event.label }} <br>
  {{ event.location }} <br>
  {{ event.description }} <br>

{% endfor %}
```

**Example output of the code (Using an HTML table and CSS styling):**

<img src="https://mintcdn.com/reportana/Jha6odPLZMMTun1e/for-en.png?fit=max&auto=format&n=Jha6odPLZMMTun1e&q=85&s=6e5e36f9602f2fea08bb8be3e6803b8f" alt="Example of `for` loop" width="919" height="365" data-path="for-en.png" />

Inside the loop, we use `event.variable` to access each part of the tracking update. This simplified approach allows us to display all tracking updates clearly and organized. It is important to note that you can use *HTML* together with *CSS* to enhance the presentation of iterated information in email messages.
