title: Twig loop. control class names
body: <p>Im trying in Twig to set different classes depending on how may items that gets rendered. Eg, if only one, if only two, if only three etc I want to set a different class on the <li> item. How would I do that?</p>
  
  <pre><code>&lt;ul&gt;
      {% for item in items %}
          &lt;li&gt;
              {% include 'components/list/person.twig' with item %}
          &lt;/li&gt;       
      {% endfor %}
  &lt;/ul&gt;
  </code></pre>