Open sheggi opened 1 year ago
Same error in situation when a *.gql file contain more than one request.
If the file has been splitted into files which one request=one file, that error gone.
Parse gql file with more than one request effects the error
@leaderit If your concern is, that multiple requests in a single .gql file should be supported, you'll be better served raising your issue in the GraphQL code generation project https://the-guild.dev/graphql/codegen. This nuxt module just uses the codegen features and has no influence in it.
In your case, I'd rather guess that there is an error in your .gql file with multiple requests because I didn't have had any problems with multiple requests in one single file.
I'd also really appreciate this, as it would allow for hot-reloading to continue to work even if errors have been typed.
This could also just be a configuration flag failOnError
or similar.
@Diizzayy any update?
Environment
Darwin
v18.13.0
3.1.0
2.0.0
yarn@1.22.19
vite
modules
,runtimeConfig
,css
,components
,postcss
,vite
nuxt-graphql-client@0.2.24
-
Describe the bug
When starting
nuxt dev
the process stops/fails if any gql file has an invalid query. This may happen if the schema changes meanwhile.Error Message:
This would prevent any rebuild or regeneration of the gql file later during the startup.
Expected behaviour
In
dev is true
just log the error and continue.In
dev is false
stop process to prevent build success.Reproduction
No response
Additional context
No response
Logs