saber-plugin-query-posts: Pagination 'next' and 'prev' links seems to be incorrect
Opened this issue ยท 5 comments
Bug report
Steps to reproduce
Fresh install Saber, install and followed saber-plugin-query-posts readme to make a blog post with pagination.
What is expected?
On the first paginated page, hasNext
should be true
, hasPrev
should be false
, same for nextLink
and prevLink
What is actually happening?
hasNext
and hasPrev
seems to be reversed
Other relevant information
- Result of running
saber -v
: latest - Browser version (optional): Chromium version 78.0.3904.87 (Official Build) Arch Linux (64-bit)
- Is Saber a global or local install? Local
- Which package manager did you use for the install? NPM
- Does this issue occur when all plugins are disabled? No
Awesome Saber! โก
Issue-Label Bot is automatically applying the label bug
to this issue, with a confidence of 0.86. Please mark this comment with ๐ or ๐ to give our bot feedback!
Links: app homepage, dashboard and code for this bot.
I think it's showing the latest posts first, therefore hasPrev
would mean has previous posts? As you can see, The order of the posts is
My Example Post 4
My Example Post 3
My Example Post 2
Therefore it's a question of semantics and not really a bug. You could rename the Prev Page
link to read Older posts
instead, and the behaviour would be correct, right?
Maybe we should reverse that, it seems everyone else is using next for older stuff ๐
@andreasvirkus Okay that make sense, yes you're right, I am using that for workaround now. Thanks!
@egoist would you want to switch the wording? Should we keep this backwards compatible? Or is it a suitable breaking change for v1?