jekyll-category-archive-plugin icon indicating copy to clipboard operation
jekyll-category-archive-plugin copied to clipboard

There are no way to grab list of generated category pages

Open shigeya opened this issue 11 years ago • 3 comments

Generated category pages are appended to master site.pages variable. There is a request to implement list of generated category pages. Possibly, site.category_pages.

shigeya avatar Sep 21 '14 14:09 shigeya

Shigeya - I just use this:

{% for category in site.categories %}
    {% categorylink post.category %}
      {{ category | first }}
    {% endcategorylink %}
  {% endfor %}

joenorton avatar Oct 27 '14 01:10 joenorton

Thank you. will check and will follow-up.

shigeya avatar Oct 27 '14 04:10 shigeya

Set the desired path in the config:

category_archive:
  path: /blog/

List all categories. Create a link:

<div class="categories">
    <ul class="nav nav-pills">
      {% for category in site.categories %}
      <li><a href="/blog/{{ category[0] }}">{{ category[0] }}</a></li>
      {% endfor %}
    </ul>
</div>

franzos avatar Feb 04 '15 22:02 franzos