absinthe v1.4.13 Absinthe.Type.Argument View Source
Used to define an argument.
Usually these are defined using Absinthe.Schema.Notation.arg/2
Link to this section Summary
Functions
Build an AST of the args map for inclusion in other types
Link to this section Types
Argument configuration
:name
- The name of the argument, usually assigned automatically usingAbsinthe.Schema.Notation.arg/2
.:type
- The type values the argument accepts/will coerce to.:deprecation
- Deprecation information for an argument, usually set-up usingAbsinthe.Schema.Notation.deprecate/1
.:description
- Description of an argument, useful for introspection.
Link to this section Functions
Build an AST of the args map for inclusion in other types
Examples
iex> build([foo: [type: :string], bar: [type: :integer]])
{:%{}, [],
[foo: {:%, [],
[{:__aliases__, [alias: false], [:Absinthe, :Type, :Argument]},
{:%{}, [], [name: "foo", type: :string]}]},
bar: {:%, [],
[{:__aliases__, [alias: false], [:Absinthe, :Type, :Argument]},
{:%{}, [], [name: "bar", type: :integer]}]}]}