paginationrubygemsjekylljekyll-paginator

Pagination with Blog/index.html in Jekyll-3.2.1


I am having a problem that seems to be somewhat common with using pagination on pages other than index.html in a Jekyll project.

I found this post that seemed to be exactly what I am looking for:

Jekyll Pagination on every page

However, the solution does not work for me. According to the documentation on Jekyll's website, the following code in _config.yml should change the paginator to use /Blog/index.html rather than /index.html:

gems: [jekyll-paginate]
paginate: 2
paginate_path: "/blog/page:num/"

I have rebuilt and restarted my local server, but the paginator still only works on the /index.html and not /Blog/index.html.

Does anyone have an idea what I could be missing here?


Solution

  • The paginator internal logic is to :

    In your case Blog/index.html is not recognized as existing in /blog/ path, because Blog != blog.

    Or you rename your containing folder to blog, or you set paginate_path: "/Blog/page:num/"