Sha256: 3309484fd2645b9d6fd9292e39ba60c92b378c137ff2efc52d0d6eefcaf28b47

Contents?: true

Size: 408 Bytes

Versions: 1

Compression:

Stored size: 408 Bytes

Contents

# frozen_string_literal: true
module GraphQL
  module Define
    module AssignGlobalIdField
      def self.call(type_defn, field_name, **field_kwargs)
        resolve = GraphQL::Relay::GlobalIdResolve.new(type: type_defn)
        GraphQL::Define::AssignObjectField.call(type_defn, field_name, **field_kwargs, type: GraphQL::Deprecation_ID_TYPE.to_non_null_type, resolve: resolve)
      end
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
graphql-1.12.2 lib/graphql/define/assign_global_id_field.rb