Method: GraphQL::Relay::RelationConnection#cursor_from_node

Defined in:
lib/graphql/relay/relation_connection.rb

#cursor_from_node(item) ⇒ Object



8
9
10
11
# File 'lib/graphql/relay/relation_connection.rb', line 8

def cursor_from_node(item)
  offset = starting_offset + paged_nodes_array.index(item) + 1
  Base64.strict_encode64(offset.to_s)
end