Reverse the order of entries?
Is it possible to list {{#allEntries}} in reverse order—oldest at the top; newest at the bottom?
Not right now, eventually I plan to add the tags required to list entries in reverse order. However, you can solve this using CSS or JS by reversing the order of the DOM nodes containing the entry links, e.g.
<div id="reverse">
{{#allEntries}}
<a href="{{{url}}}">{{title}}</a><br>
{{/allEntries}}
</div>
<script type="text/javascript">
var parent = document.getElementById('reverse');
for (var i = 1; i < parent.childNodes.length; i++){
var child = parent.childNodes[i];
parent.insertBefore(child, parent.firstChild);
}
</script>
There are also CSS-only strategies using Flexbox, e.g.
#reverse {
display:flex;
flex-direction: column-reverse;
}
Answered 2 years ago ·
Edit answer
That's weird, I've just started here and my older entries are showing at the bottom and I was trying to find out how to get them to be listed with the most recent at the top!
Answered 20 days ago · Edit answerAre you using Date
metadata or a date in the file names? Are they all dated the same?