I am creating a custom block with fields:
- field_items_to_show (items to show)
- field_logos (images, multiple)
The site editor must have the option to set the amount of items to show in a field.
in the twig field template field_logos
I need the value from field_items_to_show
<div class="logos-slide-out">
<div class="more-less wrapper d-flex-new flex-column align-items-center">
<div class="itemstoshow row d-flex-new">
{% for item in items %}
{% if loop.index == 9 %} // this value must be set from field_items_to_show
</div>
<div class="more-content itemstohide row d-flex-new">
{% endif %}
<div class="item col-sm-3 mb-30">{{ item.content }}</div>
{% endfor %}
</div>
</div>
</div>