lib/turf/helpers.rb
def feature(geom, properties: {}, bbox: nil, id: nil)
    feat = {
      type: "Feature",
      properties: properties,
      geometry: geom
    }
    feat[:id] = options[:id] if id
    feat[:bbox] = options[:bbox] if bbox

    feat
  end
# Wraps a GeoJSON Geometry in a GeoJSON Feature.
# @see https://turfjs.org/docs/#feature
# @param geom [Geometry] input geometry
# @param properties [Hash] an Object of key-value pairs to add as properties
# @param bbox [Array<number>] Bounding Box Array [west, south, east, north] associated with the Feature
# @param id [string | number] Identifier associated with the Feature
# @return [Feature] a GeoJSON Feature
Wraps a GeoJSON Geometry in a GeoJSON Feature.
Wraps a GeoJSON Geometry in a GeoJSON Feature .
def feature(geom, properties: {}, bbox: nil, id: nil)
    feat = {
      type: "Feature",
      properties: properties,
      geometry: geom
    }
    feat[:id] = options[:id] if id
    feat[:bbox] = options[:bbox] if bbox
    feat
  end
def feature ( geom , properties : { } , bbox : nil , id : nil ) feat = { type : "Feature" , properties : properties , geometry : geom } feat [ :id ] = options [ :id ] if id feat [ :bbox ] = options [ :bbox ] if bbox feat end
Wraps a GeoJSON Geometry in a GeoJSON Feature.
Wraps a GeoJSON Geometry in a GeoJSON Feature .
a GeoJSON Feature
a GeoJSON Feature
Feature
geom
None
properties
an Object of key-value pairs to add as properties
an Object of key - value pairs to add as properties
bbox
Bounding Box Array [west, south, east, north] associated with the Feature
Bounding Box Array [ west south east north ] associated with the Feature
id
Identifier associated with the Feature
Identifier associated with the Feature
see
None