Sha256: dabf8c9558564c47cc5f4e7a731be2eb54ef7da3f81ff373dadf2547e97e9630

Contents?: true

Size: 183 Bytes

Versions: 12

Compression:

Stored size: 183 Bytes

Contents

GraphQL::FLOAT_TYPE = GraphQL::ScalarType.define do
  name "Float"
  coerce_input -> (value) { value.is_a?(Numeric) ? value.to_f : nil }
  coerce_result -> (value) { value.to_f }
end

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
graphql-0.16.1 lib/graphql/float_type.rb
graphql-0.16.0 lib/graphql/float_type.rb
graphql-0.15.3 lib/graphql/float_type.rb
graphql-0.15.2 lib/graphql/float_type.rb
graphql-0.14.2 lib/graphql/float_type.rb
graphql-0.15.1 lib/graphql/float_type.rb
graphql-0.15.0 lib/graphql/float_type.rb
graphql-0.14.1 lib/graphql/float_type.rb
graphql-0.14.0 lib/graphql/float_type.rb
graphql-0.13.0 lib/graphql/float_type.rb
graphql-0.12.1 lib/graphql/float_type.rb
graphql-0.12.0 lib/graphql/float_type.rb