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

Can this be used with GraphQL-Ruby? #39

Open
nimmolo opened this issue Nov 6, 2021 · 1 comment
Open

Can this be used with GraphQL-Ruby? #39

nimmolo opened this issue Nov 6, 2021 · 1 comment

Comments

@nimmolo
Copy link

nimmolo commented Nov 6, 2021

It seems like it, but i don't understand the implementation of a connections wrapper well enough to really get it.

I'm guessing this would handle creating the "connection" without calling Types::Posts.connection_type?

@nicolas-fricke
Copy link
Member

I have not used graphql-ruby yet, but as long as you use ActiveRecord, I don't see why it shouldn't work 😃 If you pass the right params to the gem, what it returns you a Hash object with the cursor-paginate results. Take a look at the Usage section of the README.md for a bit more detail about how to invoke the paginator and what it'll return.

If you give it a try in combination with GraphQL-Ruby, please report back how it went! Might be interesting to others, too 🎉

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