Sha256: 994bad3f3ec056fa912d91b63ed45455230fc07c5621212020aebb281523d932

Contents?: true

Size: 392 Bytes

Versions: 20

Compression:

Stored size: 392 Bytes

Contents

class Functions::<%= class_name %> < GraphQL::Function
  # Define `initialize` to store field-level options, eg
  #
  #     field :myField, function: Functions::<%= class_name %>.new(type: MyType)
  #
  # attr_reader :type
  # def initialize(type:)
  #   @type = type
  # end

  # add arguments by type:
  # argument :id, !types.ID

  # Resolve function:
  def call(obj, args, ctx)
  end
end

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
graphql-1.8.1 lib/generators/graphql/templates/function.erb
graphql-1.8.0 lib/generators/graphql/templates/function.erb
graphql-1.8.0.pre11 lib/generators/graphql/templates/function.erb
graphql-1.8.0.pre10 lib/generators/graphql/templates/function.erb
graphql-1.7.14 lib/generators/graphql/templates/function.erb
graphql-1.8.0.pre9 lib/generators/graphql/templates/function.erb
graphql-1.8.0.pre8 lib/generators/graphql/templates/function.erb
graphql-1.7.13 lib/generators/graphql/templates/function.erb
graphql-1.8.0.pre7 lib/generators/graphql/templates/function.erb
graphql-1.7.12 lib/generators/graphql/templates/function.erb
graphql-1.7.11 lib/generators/graphql/templates/function.erb
graphql-1.7.10 lib/generators/graphql/templates/function.erb
graphql-1.8.0.pre6 lib/generators/graphql/templates/function.erb
graphql-1.8.0.pre5 lib/generators/graphql/templates/function.erb
graphql-1.7.9 lib/generators/graphql/templates/function.erb
graphql-1.8.0.pre4 lib/generators/graphql/templates/function.erb
graphql-1.8.0.pre3 lib/generators/graphql/templates/function.erb
graphql-1.7.8 lib/generators/graphql/templates/function.erb
graphql-1.8.0.pre2 lib/generators/graphql/templates/function.erb
graphql-1.7.7 lib/generators/graphql/templates/function.erb