Liquid error: Array 'abc' is not paginateable

Hi,

Code is follow, it popup error, Liquid error: Array ‘abc’ is not paginateable.

How to make it work?

{%- paginate abc by 10 -%}
data

{{ paginate | default_pagination: next: ‘Older’, previous: ‘Newer’ }}
{%- endpaginate -%}

You can only use paginate with a liquid array

Liquid tags: paginate (shopify.dev)

The paginate data is custom data from Ajax request, not in this array.

Yes and that’s why you can’t use it.

If you want to paginate your javascript data then you will need to create one in javascript. The liquid paginate only works with liquid arrays - specifically the ones listed above

Could you advise why I am getting the following error/reply with corrected code?

Liquid error (sections/blog-template line 7): Array ‘blog.articles’ is not paginateable.

{% if section.settings.blog_post != blank %}
{% assign limit = section.settings.blog_post %}
{% else %}
{% assign limit = 3 %}
{% endif %}

{% paginate blog.articles by limit %}

    {% for article in blog.articles %} {% include 'blog-item' %} {% endfor %}

{% if paginate.pages > 1 %}
{% include ‘pagination’ %}
{% endif %}

{% endpaginate %} .halo-blog-content .article-details .article-excerpt { text-align: {{ section.settings.blog_text_align }}; }