gi-nx / syncToProjects
ts
function syncToProjects(fc: ProjectFeatureCollection, idGetter: (f: Project) => string): Promise<number[]>;Useful to bulk sync a list of projects/geometries from outside of Giraffe and make corresponding projects in Giraffe.
Use With Caution! This can create many duplicate projects if used incorrectly.
Parameters
| Parameter | Type | Description |
|---|---|---|
fc | ProjectFeatureCollection | FeatureCollection containing a polygon for each project (existing or to be created) |
idGetter | (f: Project) => string | A function to extract the unique identifier for each feature, typically the project id. This will also extract the unique identifier from existing projects to determine if the project already exists. |
Returns
Promise<number[]>