Open yosef-abraham opened 4 years ago
Hello @iscriptology!
This seems a nice usage of GraphQL through a Flutter app! I like to use it on relay as well (though one downside is queries end up scattered across the repository and this makes me mad).
However, Artemis is a pure Dart library, and this wouldn't be its responsability to handle: it'd be nice to have a new GraphQL client library that leverages both Artemis type generation and this relay-style annotation-based usage.
If you'd like to start some implementation on this, please reach me and I can assist on the Artemis integration!
@comigor thanks for the reply.
Even though a specific graphql client adjusted for this use case would be nice, it still is fully backward compatible to just source the graphql queries from the gql
annotations in addition to the .graphql
files.
This can be done here at artemis regardless of any client being implemented.
What do you think?
Absolutely! We just need to keep configurations working and share fragments/enums/input types correctly.
But to be honest, this implementation is not a priority right now, but I'll gladly assist you if you want to start it!
In relay, one of the strength points is that queries and fragments can be written along side the widgets using them.
We had a discussion regarding this here.
For example:
I also have been able to make vscode to auto-complete me inside the annotation's query.
What do you think?