Menu act differently depending the page

9 0 0



I've build a custom menu for our ecommerce website. I have a problem ONLY on the blog page


If you take a look at the lights menu. You have 3 products in "Best Sellers". these 3 products showing well on every website pages but on the blog page ... It's broken.

The problem comes from here because when you are in mobil version you can interact with the lights menu but the other one after are buggy and when I'm deleting this code that's work well.


This is my liquid code:

                        {% if forloop.index == 3 %}
                          <h3 class="title heading"> {{sub_link.title}}</h3>
                          {% paginate sub_link.object.products by 3 %}
                            {% for product in sub_link.object.products %}
                              {%- render 'product-item', product: product, show_add_to_cart: false, grid_classes: '1/3--lap 1/3--desk 1/3--wide', show_review: false, horizontal: true -%}
                            {% endfor %}
                          {% endpaginate %}
                        {% endif %}

On the third iteration (third items in my menu) I have the link to a collection Best sellers and I showing that in the menu. I don't clearly understand what happenning and why this behavior append only on the main blog page.


Do you have any ideas?