sverrirs / jekyll-paginate-v2

Pagination Generator for Jekyll 3 (enhanced replacement for the old built-in jekyll-paginate gem) ⛺
https://rubygems.org/gems/jekyll-paginate-v2
MIT License
524 stars 289 forks source link

Option for pagination sort_field to use manual collection order in Jekyll 4 #220

Open gregpass opened 3 years ago

gregpass commented 3 years ago

In Jekyll 4 it is possible to manually order a collection in _config.yml, e.g..

collections:
  foo:
    output: true
    order:
      - bar.md
      - xyzz.md

Ideally the pagination config could refer to this order:

pagination:
  enabled: true
  collection: foo
  sort_field: 'order' <-- 'order' may conflict with post front matter so another special value may be better
  sort_reverse: false