dif %}
    </h2>
    {% set monthly_posts = posts | group_by(attribute="month") %}
    {% for month, posts in monthly_posts %}
    {% set month_name = posts[0].date | date(format="%B") %}
    <div class="archive-month">
        <h3 class="archive-month-header">{{ month_name }}
        {% if config.extra.papermod.show_archive_month_count is not defined or config.extra.papermod.show_archive_month_count %}
            <sup class="archive-count">&nbsp;&nbsp;{{ posts | length }}</sup>
        {% endif %}
       