Pagination Not working in Custom Template

Hello,

While i am trying to use the pagination in Custom Template for my Homepage Variation 2. It does not working there. I am not getting any data inside the condition.

Here following the code what i used in pagination.hbs.

<ul>
    {{#if prev}}
        <li class="prev-left"><a href="{{page_url prev}}"><i class="fa fa-angle-double-left" aria-hidden="true"></i></a></li>
    {{/if}}
    
    {{#if next}}
        <li class="next-right"><a href="{{page_url next}}"><i class="fa fa-angle-double-right" aria-hidden="true"></i></a></li>
    {{/if}}
</ul>

Pagination only working in my index.hbs but it does not working in custom-home.hbs

Thanks

I have the same issue, is the any documentation to getting the pagination working on a custom template?

1 Like

No. that is a limitation i think. so can use pagination there

i got it working, have to make changes in routes.yaml - home is my static homepage

routes:
/: home

collections:
/blog/:
permalink: /blog/{slug}/
template:
- index