Description templates
Let's say that you have a type
that you want to reuse in other types:
Source GraphQXL | Compiled GraphQL |
|
|
There, foo
's description says that the field foo
belongs to the type ToBeReused
,
but once that is compiled it is not true, it should say something like:
input Bar {
"Field foo from input 'Bar'"
foo: String!
}
Description string interpolation
You can use template variables in the description strings to refer to some contextual values:
Source GraphQXL | Compiled GraphQL |
|
|
These are the available values for the templates:
- block.name: The parent's block name
- block.type: The parent's block type (
type
orinput
) - variables.YOUR_GENERIC_VARIABLE: The value of the generic variable once instanced