how does ApolloClient.query()
behave when using cursor for pagination?
here is my query:
query MyQuery {
events {
edges {
cursor
node {
blockHeight
}
}
pageInfo {
endCursor
hasNextPage
}
}
}
it’s behaves as expected when querying directly from the graphql endpoint, it returns the first few entries along with endCursor that I can use to retrive next page. But, when using ApolloClient.query() method, it seems to skip over all the starting entries and return the last few pages. Is it possible that ApolloClient.query() is making repeated queries for consecutive pages and overwriting the previous ones? I also see that the response time is abnormally high and it timeouts at db level more often than not.