Docs: improve typing of FeatureSources

This commit is contained in:
Pieter Vander Vennet 2025-08-20 01:12:09 +02:00
parent c71036d6c6
commit 34924fd4b1
21 changed files with 140 additions and 127 deletions

View file

@ -54,11 +54,11 @@ export class GeoOperations {
/**
* Create a union between two features
*/
public static union(
public static union<P >(
f0: Feature<Polygon | MultiPolygon>,
f1: Feature<Polygon | MultiPolygon>
): Feature<Polygon | MultiPolygon> | null {
return turf.union(turf.featureCollection([f0, f1]))
): Feature<Polygon | MultiPolygon, P> | null {
return turf.union<P>(turf.featureCollection([f0, f1]))
}
public static intersect(