I am trying to select 2 media elements per div rendered using the receptar theme in each rendering of blog_item element. In other words, I need to display a container that holds divs, where each div displays two images. The first div would have image1 and image2, the second dive would have image3 and image4, etc... My blog_item.html.twig looks like this:
<div id="post-{{ loop.index }}" class="post-{{ loop.index }} post type-post status-publish format-standard has-post-thumbnail hentry category-cakes tag-no-excerpt">
<div class="entry-media {% if truncate %}entry-{% if page.header.youtube or page.header.soundcloud or page.header.vimeo %}video{% else %}image{% endif %}{% else %} resp_video{% endif %}">
<div class="post-thumbnail">
{% if page.media.images|first %}
{{ page.media.images|first.cropZoom(338,451).html('','', 'attachment-receptar-featured size-receptar-featured wp-post-image')|raw }}
{% if page.header.text %}
<div class="image-text">
<span>
{{page.header.text}}
</span>
</div>
{% endif %}
{% else %}
<img class="attachment-receptar-featured size-receptar-featured wp-post-image" src="{{ theme_url }}/images/{{ site.global_featured_image }}">
{% endif %}
</div>
</div>
</div>
I'm still learning the calls that come after the pipe such as
|first
I'm thinking it might be specified there but not sure...
Thank you!


