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

feat: Add custom name options to Relay Connection plugin #744

Merged
merged 2 commits into from
Jan 7, 2021
Merged

feat: Add custom name options to Relay Connection plugin #744

merged 2 commits into from
Jan 7, 2021

Conversation

migueloller
Copy link
Contributor

Adds a getConnectionName and getEdgeName option to both the global
plugin config as well as the field config for the Relay Connection
plugin. This gives the user the ability to control the names of the
generated connection and edge types in the schema.

Closes #697

Prettier seems to have re-formatted some comments. I can remove these changes or put them in a separate commit if needed. Also, please let me know if the option descriptions and the tests are acceptable.

cc: @tgriesser

@migueloller
Copy link
Contributor Author

Seems the original commit was based on a stale develop branch. I've rebased against main, so there should be no conflicts now.

@codecov
Copy link

codecov bot commented Dec 18, 2020

Codecov Report

Merging #744 (a79087a) into main (9afc643) will increase coverage by 0.01%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main     #744      +/-   ##
==========================================
+ Coverage   93.77%   93.78%   +0.01%     
==========================================
  Files          46       46              
  Lines        2922     2930       +8     
  Branches      688      692       +4     
==========================================
+ Hits         2740     2748       +8     
  Misses        180      180              
  Partials        2        2              

@migueloller
Copy link
Contributor Author

Hey @tgriesser. Happy new year!

Have you had a chance to take a look at this PR? Anything you want to add or change?

@tgriesser
Copy link
Member

Nope, seems good! Mind rebasing it one more time? I'll look to get this merged in right away

Adds a getConnectionName and getEdgeName option to both the global
plugin config as well as the field config for the Relay Connection
plugin. This gives the user the ability to control the names of the
generated connection and edge types in the schema.

Closes #697
@migueloller
Copy link
Contributor Author

Done!

@tgriesser tgriesser changed the title Add custom name options to Relay Connection plugin feat: Add custom name options to Relay Connection plugin Jan 7, 2021
@tgriesser tgriesser merged commit 4f3cef9 into graphql-nexus:main Jan 7, 2021
@migueloller migueloller deleted the migueloller/connection-plugin-names branch January 7, 2021 03:09
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.

Ability to control the name of connection and edge types
2 participants