# src/MyBundle/Resources/config/graphql/HumanAndDroid.types.yml
#
# This implements the following type system shorthand:
# input HeroInput {
# name: Episode!
# }
HeroInput:
type: input-object
config:
fields:
name:
type: "String!"
Note: If the attribute name is not set on the [@GQL](https://github.com/GQL)\Input, the final name will be the class name suffixed by "Input" if it doesn't have already the suffix. (ex: If the class name is Hero the input name will be HeroInput).
With Input type, the [@Field](https://github.com/Field) annotation on methods are ignored, so is the annotations on properties that need a resolver.
<?php
namespace AppBundle;
use Overblog\GraphQLBundle\Annotation as GQL;
/**
* [@GQL](https://github.com/GQL)\Input
*/
class HeroInput
{
/**
* [@GQL](https://github.com/GQL)\Field(type="String!")
*/
public $name;
}
How can I help you explore Laravel packages today?