import * as unionOperator from "@arcgis/core/geometry/operators/unionOperator.js";
const unionOperator = await $arcgis.import("@arcgis/core/geometry/operators/unionOperator.js");
@arcgis/core/geometry/operators/unionOperator
Perform a topological union (dissolve) operation on 2D geometries.

Property Overview
| Name | Type | Summary | Object |
|---|---|---|---|
Indicates if the operator supports input geometries that contain curves. | unionOperator |
Property Details
-
supportsCurves
PropertysupportsCurves Booleanreadonly -
Indicates if the operator supports input geometries that contain curves. The value will always be
true.
Method Overview
| Name | Return Type | Summary | Object |
|---|---|---|---|
Perform a topological union operation on two geometries. | unionOperator | ||
Perform a topological union operation on a geometry set. | unionOperator |
Method Details
-
execute
Methodexecute(geometry1, geometry2){GeometryUnion |null |undefined} -
Perform a topological union operation on two geometries.
Parametersgeometry1 GeometryUnionThe first geometry to union with.
geometry2 GeometryUnionThe second geometry to union with.
ReturnsType Description GeometryUnion | null | undefined Returns the union of the two geometries as a geometry or null. Example// Return the union of two polygons const union = unionOperator.execute(polygon1, polygon2);
-
executeMany
MethodexecuteMany(geometries){GeometryUnion |null |undefined} -
Perform a topological union operation on a geometry set.
Parametergeometries GeometryUnion[]The array of geometries to union. All the geometries must have the same spatial reference.
ReturnsType Description GeometryUnion | null | undefined Returns the union of geometriesas a geometry or null.