All Downloads are FREE. Search and download functionalities are using the official Maven repository.

package.dist.js.index.d.ts Maven / Gradle / Ivy

There is a newer version: 7.1.0
Show newest version
import { Feature, FeatureCollection, Geometry } from "@turf/helpers";
/**
 * Takes one or more features and returns their area in square meters.
 *
 * @name area
 * @param {GeoJSON} geojson input GeoJSON feature(s)
 * @returns {number} area in square meters
 * @example
 * var polygon = turf.polygon([[[125, -15], [113, -22], [154, -27], [144, -15], [125, -15]]]);
 *
 * var area = turf.area(polygon);
 *
 * //addToMap
 * var addToMap = [polygon]
 * polygon.properties.area = area
 */
export default function area(geojson: Feature | FeatureCollection | Geometry): number;




© 2015 - 2024 Weber Informatics LLC | Privacy Policy