Rename the variable for #47
This commit is contained in:
parent
38cfa275d2
commit
03bb550d46
2 changed files with 2 additions and 2 deletions
|
@ -1,4 +1,4 @@
|
|||
<ol reversed class="postlist" style="counter-reset: start-from {{ (counterOffset or postslist.length) + 1 }}">
|
||||
<ol reversed class="postlist" style="counter-reset: start-from {{ (postslistCounter or postslist.length) + 1 }}">
|
||||
{% for post in postslist | reverse %}
|
||||
<li class="postlist-item{% if post.url == url %} postlist-item-active{% endif %}">
|
||||
<a href="{{ post.url | url }}" class="postlist-link">{% if post.data.title %}{{ post.data.title }}{% else %}<code>{{ post.url }}</code>{% endif %}</a>
|
||||
|
|
|
@ -8,7 +8,7 @@ eleventyNavigation:
|
|||
<h1>Latest 3 Posts</h1>
|
||||
|
||||
{% set postslist = collections.posts | head(-3) %}
|
||||
{% set counterOffset = collections.posts | length %}
|
||||
{% set postslistCounter = collections.posts | length %}
|
||||
{% include "postslist.njk" %}
|
||||
|
||||
<p>More posts can be found in <a href="{{ '/posts/' | url }}">the archive</a>.</p>
|
||||
|
|
Loading…
Add table
Reference in a new issue