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

Start Relay Resolver Docs with basic examples #480

Closed

Conversation

youngkidwarrior
Copy link
Contributor

@youngkidwarrior youngkidwarrior commented Dec 11, 2023

Created these based off the part of resolvers I have used. I tried to take a stab at graphql fragment arguments, but I have never had to use those so not sure if correct

I just used the UserGreeting example the relay docs used. We might want a more "rescripty" example that shows off how well resolvers work with Variants and switch statement

TODO:

  • Check graphql argument code and make sure it is correct
  • Write docs passing runtime arguments

Copy link
Owner

@zth zth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking great!

Comment on lines +43 to +45
* @onType User
* @fieldName greeting
* @rootFragment GreetingResolver
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think there's a more compact notation now that we could perhaps also show. Can't find a link to it now though.

@zth
Copy link
Owner

zth commented Dec 12, 2023

I haven't tried passing JS arguments to resolvers in RescriptRelay yet myself. I would assume we need some deeper integration for that to work.

@youngkidwarrior
Copy link
Contributor Author

Okay, I'll take that part out for now

@zth
Copy link
Owner

zth commented Aug 1, 2024

Superseded by recent doc updates. Thanks for the effort anyway!

@zth zth closed this Aug 1, 2024
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

Successfully merging this pull request may close these issues.

None yet

2 participants