jekyll / jekyll-paginate

NO LONGER UNDER ACTIVE DEVELOPMENT as of Jekyll 3: Pagination Generator for Jekyll
MIT License
111 stars 84 forks source link

Import checks from Jekyll #39

Closed DirtyF closed 5 years ago

DirtyF commented 6 years ago

Discussed in https://github.com/jekyll/jekyll/issues/6391

/cc @sverrirs

ashmaroli commented 6 years ago

https://github.com/jekyll/jekyll/blob/4c97f5ef222465916c499f5d7a1bace9d1a40650/lib/jekyll/renderer.rb#L211-L213

    # Set page content to payload and assign pager if document has one.
    #
    # Returns nothing
    private
    def assign_pages!
      payload["page"] = document.to_liquid
      payload["paginator"] = if document.respond_to?(:pager)
                               document.pager.to_liquid
                             end
    end
parkr commented 6 years ago

@ashmaroli That should be in a Hook, I think.

These could both be hooks, I guess.