Sha256: ab0e29c8f26db13ead6741d8e5afdd54e56b86196c3b82ac77ba30ee0e2c5013

Contents?: true

Size: 763 Bytes

Versions: 47

Compression:

Stored size: 763 Bytes

Contents

# frozen_string_literal: true
module GraphQL
  module Relay
    # Wrap a Connection and expose its page info
    PageInfo = GraphQL::ObjectType.define do
      name("PageInfo")
      description("Information about pagination in a connection.")
      field :hasNextPage, !types.Boolean, "When paginating forwards, are there more items?", property: :has_next_page
      field :hasPreviousPage, !types.Boolean, "When paginating backwards, are there more items?", property: :has_previous_page
      field :startCursor, types.String, "When paginating backwards, the cursor to continue.", property: :start_cursor
      field :endCursor, types.String, "When paginating forwards, the cursor to continue.", property: :end_cursor
      default_relay true
    end
  end
end

Version data entries

47 entries across 47 versions & 1 rubygems

Version Path
graphql-1.8.3 lib/graphql/relay/page_info.rb
graphql-1.8.2 lib/graphql/relay/page_info.rb
graphql-1.8.1 lib/graphql/relay/page_info.rb
graphql-1.8.0 lib/graphql/relay/page_info.rb
graphql-1.8.0.pre11 lib/graphql/relay/page_info.rb
graphql-1.8.0.pre10 lib/graphql/relay/page_info.rb
graphql-1.7.14 lib/graphql/relay/page_info.rb
graphql-1.8.0.pre9 lib/graphql/relay/page_info.rb
graphql-1.8.0.pre8 lib/graphql/relay/page_info.rb
graphql-1.7.13 lib/graphql/relay/page_info.rb
graphql-1.8.0.pre7 lib/graphql/relay/page_info.rb
graphql-1.7.12 lib/graphql/relay/page_info.rb
graphql-1.7.11 lib/graphql/relay/page_info.rb
graphql-1.7.10 lib/graphql/relay/page_info.rb
graphql-1.8.0.pre6 lib/graphql/relay/page_info.rb
graphql-1.8.0.pre5 lib/graphql/relay/page_info.rb
graphql-1.7.9 lib/graphql/relay/page_info.rb
graphql-1.8.0.pre4 lib/graphql/relay/page_info.rb
graphql-1.8.0.pre3 lib/graphql/relay/page_info.rb
graphql-1.7.8 lib/graphql/relay/page_info.rb