Sha256: dd020c86fe404e23c4f5d6e127dd0e38ec3ef12dcdc25a3f1adf3ca811176aab
Contents?: true
Size: 815 Bytes
Versions: 1
Compression:
Stored size: 815 Bytes
Contents
# frozen_string_literal: true GraphQL::Introspection::InputValueType = GraphQL::ObjectType.define do name "__InputValue" description "Arguments provided to Fields or Directives and the input fields of an "\ "InputObject are represented as Input Values which describe their type and "\ "optionally a default value." field :name, !types.String field :description, types.String field :type, !GraphQL::Introspection::TypeType field :defaultValue, types.String, "A GraphQL-formatted string representing the default value for this input value." do resolve ->(obj, args, ctx) { if obj.default_value? value = obj.default_value value.nil? ? 'null' : GraphQL::Language.serialize(obj.type.coerce_result(value)) else nil end } end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
graphql-1.3.0 | lib/graphql/introspection/input_value_type.rb |