Rename template files for content categories
This commit is contained in:
parent
ec2431bb02
commit
c18644199f
|
@ -1,18 +0,0 @@
|
||||||
---
|
|
||||||
title: Content Categories
|
|
||||||
permalink: /categories/
|
|
||||||
eleventyComputed:
|
|
||||||
desc: All content categories on {{ sitemeta.siteName | safe }}.
|
|
||||||
eleventyNavigation:
|
|
||||||
order: 10
|
|
||||||
---
|
|
||||||
|
|
||||||
<ul>
|
|
||||||
{% for category in collections.categories %}
|
|
||||||
{% set categoryUrl %}/categories/{{ category | slugify }}/{% endset %}
|
|
||||||
{% set categoryPostCount = collections.contents | filterByCategory(category) | length %}
|
|
||||||
<li><a href="{{ categoryUrl }}">{{ category }}</a> ({{ categoryPostCount }})</li>
|
|
||||||
{% endfor %}
|
|
||||||
</ul>
|
|
||||||
|
|
||||||
<p>See all contents on this website in the <a href="/archive/">archive</a>.</p>
|
|
|
@ -1,19 +1,17 @@
|
||||||
---
|
---
|
||||||
pagination:
|
title: Content Categories
|
||||||
data: collections.categories
|
|
||||||
size: 1
|
|
||||||
alias: category
|
|
||||||
permalink: /categories/{{ category | slugify }}/
|
|
||||||
eleventyExcludeFromCollections: true
|
|
||||||
eleventyComputed:
|
eleventyComputed:
|
||||||
title: 'Content Category: "{{ category | safe }}"'
|
desc: All content categories on {{ sitemeta.siteName | safe }}.
|
||||||
desc: All contents under the "{{ category | safe }}" category on {{ sitemeta.siteName | safe }}.
|
eleventyNavigation:
|
||||||
|
order: 10
|
||||||
---
|
---
|
||||||
|
|
||||||
{% set contentCount = collections.contents | filterByCategory(category) | length %}
|
<ul>
|
||||||
<h2>{{ contentCount }} Contents Filed Under "{{ category }}"</h2>
|
{% for category in collections.categories %}
|
||||||
|
{% set categoryUrl %}/categories/{{ category | slugify }}/{% endset %}
|
||||||
|
{% set categoryPostCount = collections.contents | filterByCategory(category) | length %}
|
||||||
|
<li><a href="{{ categoryUrl }}">{{ category }}</a> ({{ categoryPostCount }})</li>
|
||||||
|
{% endfor %}
|
||||||
|
</ul>
|
||||||
|
|
||||||
{% set contentList = collections.contents | filterByCategory(category) | reverse %}
|
<p>See all contents on this website in the <a href="/archive/">archive</a>.</p>
|
||||||
{% include "main/archive.njk" %}
|
|
||||||
|
|
||||||
<p>See <a href="/categories/">all content categories</a>.</p>
|
|
|
@ -0,0 +1,19 @@
|
||||||
|
---
|
||||||
|
pagination:
|
||||||
|
data: collections.categories
|
||||||
|
size: 1
|
||||||
|
alias: category
|
||||||
|
permalink: /categories/{{ category | slugify }}/
|
||||||
|
eleventyExcludeFromCollections: true
|
||||||
|
eleventyComputed:
|
||||||
|
title: 'Content Category: "{{ category | safe }}"'
|
||||||
|
desc: All contents under the "{{ category | safe }}" category on {{ sitemeta.siteName | safe }}.
|
||||||
|
---
|
||||||
|
|
||||||
|
{% set contentCount = collections.contents | filterByCategory(category) | length %}
|
||||||
|
<h2>{{ contentCount }} Contents Filed Under "{{ category }}"</h2>
|
||||||
|
|
||||||
|
{% set contentList = collections.contents | filterByCategory(category) | reverse %}
|
||||||
|
{% include "main/archive.njk" %}
|
||||||
|
|
||||||
|
<p>See <a href="/categories/">all content categories</a>.</p>
|
Loading…
Reference in New Issue