absinthe v0.5.2 Absinthe.Type.Directive
Used by the GraphQL runtime as a way of modifying execution behavior.
Type system creators will usually not create these directly.
Summary
Types
t :: %{name: binary, description: binary, args: map, on: [atom], instruction: (map -> atom), reference: Absinthe.Type.Reference.t}
A defined directive.
:name
- The name of the directivee. Should be a lowercasebinary
. Set automatically when using@absinthe :directive
fromAbsinthe.Type.Definitions
.:description
- A nice description for introspection.:args
- A map ofAbsinthe.Type.Argument
structs. SeeAbsinthe.Type.Definitions.args/1
.:on
- A list of places the directives can be used (can be:operation
,:fragment
,:field
).:instruction
- A function that, given an argument, returns an instruction for the correct action to take
The :reference
key is for internal use.