Skip to content

Fix sort order on the homepage #60

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Feb 16, 2020
Merged

Fix sort order on the homepage #60

merged 1 commit into from
Feb 16, 2020

Conversation

17cupsofcoffee
Copy link
Collaborator

As noticed by @ozkriff, the homepage wasn't actually being sorted in date order. Upon some digging, I found that they were actually being sorted in reverse alphabetical order - it just so happened that we've not broken that pattern of post names since the site launched 😆

In my defense, the Zola theme I used as reference for implementing this site also makes this mistake...

The fix is to properly sort the posts section by date, and then remove the reversing logic from the template. This also has the nice side effect of giving us access to the next/previous post as template variables, so I might integrate that into the template at a later date 😄

@ozkriff ozkriff merged commit ebf10f6 into rust-gamedev:source Feb 16, 2020
@17cupsofcoffee 17cupsofcoffee deleted the fix-sorting branch February 16, 2020 14:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants