src/index.js
function constructProps (fieldNames, feature) {
  const properties = _.reduce(fieldNames, (tempProps, fieldName, key) => {
    tempProps[fieldName] = (!isNaN(feature[key])) ? parseFloat(feature[key]) : feature[key]
    return tempProps
  }, {})
  return properties
}
function constructProps (fieldNames, feature) {
  const properties = _.reduce(fieldNames, (tempProps, fieldName, key) => {
    tempProps[fieldName] = (!isNaN(feature[key])) ? parseFloat(feature[key]) : feature[key]
    return tempProps
  }, {})
  return properties
}
function constructProps ( fieldNames , feature ) { const properties = _ . reduce ( fieldNames , ( tempProps , fieldName , key ) => { tempProps [ fieldName ] = ( ! isNaN ( feature [ key ] ) ) ? parseFloat ( feature [ key ] ) : feature [ key ] return tempProps } , { } ) return properties }
Covert fields into properties object
@param {array} fieldNames - array of field names
@param {array} feature - individual feature
@returns {object} properties - property object
Covert fields into properties object