node-red-contrib-tak-registration
Version:
A Node-RED node to register to TAK and to help wrap files as datapackages to send to TAK
27 lines (24 loc) • 1.06 kB
TypeScript
import { Geometry, Feature, FeatureCollection } from 'geojson';
import { AllGeoJSON } from '@turf/helpers';
/**
* Rewind {@link LineString|(Multi)LineString} or {@link Polygon|(Multi)Polygon} outer ring counterclockwise and inner rings clockwise (Uses {@link http://en.wikipedia.org/wiki/Shoelace_formula|Shoelace Formula}).
*
* @function
* @param {GeoJSON} geojson input GeoJSON Polygon
* @param {Object} [options={}] Optional parameters
* @param {boolean} [options.reverse=false] enable reverse winding
* @param {boolean} [options.mutate=false] allows GeoJSON input to be mutated (significant performance increase if true)
* @returns {GeoJSON} rewind Polygon
* @example
* var polygon = turf.polygon([[[121, -29], [138, -29], [138, -18], [121, -18], [121, -29]]]);
*
* var rewind = turf.rewind(polygon);
*
* //addToMap
* var addToMap = [rewind];
*/
declare function rewind<T extends AllGeoJSON>(geojson: T, options?: {
reverse?: boolean;
mutate?: boolean;
}): Geometry | Feature | FeatureCollection;
export { rewind as default, rewind };