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

generate json tag to model field by gql name. #108

Merged
merged 2 commits into from
May 8, 2018

Conversation

imiskolee
Copy link

  1. add json tag in models_gen.go
  2. use gqlname to model filed json tag.

why we need it?

use the json tag, we can easy to go test used the generated struct,and don't need write origin graphQL

2. use gqlname to model filed json tag.
@imiskolee
Copy link
Author

@vektah i can't understand the CI error.

@vektah
Copy link
Collaborator

vektah commented May 8, 2018

you need to run go generate ./...

@vektah vektah merged commit 3990eac into 99designs:master May 8, 2018
@vektah
Copy link
Collaborator

vektah commented May 8, 2018

Thanks for the PR 👍

cgxxv pushed a commit to cgxxv/gqlgen that referenced this pull request Mar 25, 2022
generate json tag to model field  by gql name.
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.

2 participants