Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Feature] Offset pagination #901

Open
0xOlias opened this issue May 20, 2024 · 1 comment
Open

[Feature] Offset pagination #901

0xOlias opened this issue May 20, 2024 · 1 comment

Comments

@0xOlias
Copy link
Collaborator

0xOlias commented May 20, 2024

The findMany store method and the GraphQL API support cursor pagination as specified here.

A number of users have also requested offset pagination to support a "jump to page" feature, eg /?page=1. There are performance considerations here, but now that we have custom database indexes, perf issues can often be mitigated in userland.

@hskang9
Copy link

hskang9 commented Jul 1, 2024

I agree with this idea. Performance is a problem, but it is not the first problem when shipping an app. Offset is inefficient, but it is effective in making pagination UI components. I believe SQL API allows OFFSET keyword, and this is unfair for GraphQL api devs. I think keeping GraphQL out of offset is unfair and a premature optimization. How can I contribute to resolve this issue?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants