These examples provide references for various configurations you can use for Jekyll Collection Pages plugin to suit youro needs.
collection_pages:
- collection: posts
field: category
path: blog/category
layout: category_page.html
paginate: 10
This configuration will create category pages for your blog posts, with 10 posts per page.
collection_pages:
- collection: docs
field: section
path: documentation/sections
layout: doc_section.html
- collection: tutorials
field: difficulty
path: tutorials/level
layout: tutorial_level.html
paginate: 5
This setup creates unpaginated section pages for documentation and paginated difficulty level pages for tutorials
collection_pages:
- collection: projects
field: tags
path: portfolio/tags
layout: project_tag.html
This configuration creates tag pages for a project portfolio, allowing visitors to brows projects by tag.
You can create pages based on multiple fields for the same collection:
collection_pages:
- collection: books
field: genre
path: books/genre
layout: book_genre.html
- collection: books
field: author
path: books/author
layout: book_author.html
This configuration creates separate pages for browsing books by genre and author.
field
exists in your document front matter_layouts
directory.