Listing 19.16. Widok akcji index
{% extends '::layout.html.twig' %}

{% block title %}
    Tatry
{% endblock %}

{% block content %}
    <h1 id="logo">Tatry</h1>
    <table>
        <thead>
            <tr>
                <th>lp.</th>
                <th>Nazwa</th>
                <th>Wysokość</th>
            </tr>
        </thead>
        <tbody>
        {% for szczyt in entities %}
            <tr>
                <td>{{ loop.index }}.</td>
                <td>{{ szczyt }}</td>
                <td>{{ szczyt.height }}</td>
            </tr>
        {% endfor %}
        </tbody>
    </table>

{% endblock %}