Replies: 3 comments 4 replies
-
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Beta Was this translation helpful? Give feedback.
-
@jwatte Have you solved this issue? |
Beta Was this translation helpful? Give feedback.
-
there are no resolvers generated for an input type (even with @fieldResolver(forceResolver: true) or specifying in gqlgen.yml) but if you add it manually it works just fine, but after any code generation your resolver will go to the bottom of the file and will be marked as unused (actually it is). as an example:
domain/user.go
code generation goes without errors - but in resolvers.go we have only the resolver for TestType
in result we have an error when running the project if we add it manually - so that our resolvers go looks like
everything works fine , but after next code generation it is marked as unused but still working:
|
Beta Was this translation helpful? Give feedback.
-
What happened?
Start with the default "gqlgen init" project structure.
Add a simple type (here "foo.Mode") to the gql schema and gqlgen.yml
re-generate
get errors:
What did you expect?
I expected appropriate glue for this type to be generated, and no compile errors.
Minimal graphql.schema and models to reproduce
versions
gqlgen version
?v0.12.2
go version
?go version go1.14 linux/amd64
go mod
Beta Was this translation helpful? Give feedback.
All reactions