Closed timpulver closed 1 year ago
I don't think Hexo gonna support it. The downside I could see is the number of static files will be overwhelming.
The site I’m building does not have that many projects / artists, so I think this should be okay.
If this is not possible, grabbing all posts, and comparing the create date to find the last / next one will probably work I guess, but I hoped there was an easier way.
I think this related to your another issue. https://github.com/hexojs/hexo/issues/2269 Could we just keep this one open and discuss the solution?
For now, I have to take a look the Hexo document to see if there is a way to suit your scenario. Or maybe it is a feature request.
Feel free to close this one / the other one. Thanks for your help!
The data type of post.prev is also post (it's like a linked list), so you can write like this
let target = post.next;
while (target.categories.data[0].name !== 'your_category' && target.next) {
target = target.next;
}
This issue has been automatically marked as stale because lack of recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Hi,
I know I can display the previous and next post on a post page using something like this:
Is it possible to use a category filter with this? I have posts with category
artist
and of categoryproject
. If on a project site I would like a next / previous button to link to the next project only, not artist.Thanks!