-
Notifications
You must be signed in to change notification settings - Fork 46
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
Directive support #645
Milestone
Comments
Need to think about how to support each of the locations for directives in executables: Field & FragmentSpread PositionsField position seems relatively easy, can take a similar approach to arguments: #[derive(QueryFragment)]
struct Whatever {
#[directive(skipIf: $someVariable)]
field: String
#[cynic(spread)]
#[directive(whatever: $xyz)]
other: SomeFragment
} Variable DefinitionSimilar for variable definitions #[derive(QueryVariables)]
struct MyVariables {
#[directive(whatever: 123)]
variable: String
} Fragment DefinitionWe don't currently support fragment definitions but this will need thought through if we decide to Query & Mutation & Subscription PositionTBC Inline FragmentTBC |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The various derives (and probably the generator) should support passing directives in.
We should probably also offer first class support for the
skip
&include
directives.The text was updated successfully, but these errors were encountered: