hi, I'm try to implement cursor pagination by look through the appwrite document and i still don't get it, could anyone send link any example code about it ?
You can check this example, should give you a gist - https://dev.to/appwrite/this-is-why-you-should-use-cursor-pagination-4nh5
i already check it and still don't get it, what i need an example code how to implement a real project
What you don't understand, basically triggering your get documents and in the query specify the page where you are
I'm using this package https://terryz.github.io/vue3/page/#page-size-menu and i'm trying to implement it with cursor paginator, what i don't understand step process like when user click on previous or next
When you click page 2, get documents as usually, with the difference you specify in your query this: Query.offset(0)
1 if you're in page 1, 2 if in page 2...
i don't get it, why offset ?
Offset = page
i'm try to implement cursor pagination not offset
Then you get latest document id and that way you get next elements
how about previous ?
anyone implement this ?
First element you just don't set pagination query so you will get first 24 documents
example : i have 3 pages , i click on page 3 and then i click on page 2 , how the query work ?
For that you need standard pagination then
Cursor pagination is for example to make an infinite scrolling screen
You can implement too cursor pagination there, but I think it's worthless
why is it worthless ?
You will need to perform multiple queries so It will take practically the same time
In other words you will not have practically any advantage
ok, noted, thank you so much.
Recommended threads
- Attribute not found in schema on REST AP...
I'm querying a appwrite collection via the REST API on appwrite cloud 1.9.5 (no SDK) via a cloudflare worker and keep getting: ``` {"message":"Invalid query: A...
- [SOLVED] Appwrite 25.1.0 returns Invalid...
I've already opened an issue on GitHub, but somewhat it doesn't seem like GitHub is monitored very closely, so I'm leaving a bug report here on Discord as well....
- Helping in unblock my account
I deleted my Appwrite Cloud account that was linked via GitHub. Now I activated my GitHub Student Pack and want to sign up again using the same GitHub account, ...