Sha256: 4d8111bb0f2df05c4a5990d7d165c00b741101b4679063e52147f9688f1ad9e3
Contents?: true
Size: 559 Bytes
Versions: 38
Compression:
Stored size: 559 Bytes
Contents
# frozen_string_literal: true module Decidim module Core # This type represents a Decidim's global property. CoordinatesType = GraphQL::ObjectType.define do name "Coordinates" description "Physical coordinates for a location" field :latitude, !types.Float, "Latitude of this coordinate" do resolve ->(coordinates, _args, _ctx) { coordinates[0] } end field :longitude, !types.Float, "Longitude of this coordinate" do resolve ->(coordinates, _args, _ctx) { coordinates[1] } end end end end
Version data entries
38 entries across 38 versions & 1 rubygems