![]() In general, we've found that cursor-based pagination is the most powerful of those designed. We could do something like friends(first:2 after:$friendCursor), where we get a cursor from the last item and use that to paginate.We could do something like friends(first:2 after:$friendId), to ask for the next two after the last friend we fetched.We could do something like friends(first:2 offset:2) to ask for the next two in the list.There are a number of ways we could do pagination: How can we enable that behavior? Pagination and Edges # But if we just fetched the first two, we might want to paginate through the list as well once the client fetches the first two friends, they might want to send a second request to ask for the next two friends.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |