geojsonType
Description
Enforce expectations about types of GeoJSON objects for Turf.
Parameters
Name | Type | Description |
---|---|---|
value | GeoJSON | any GeoJSON object |
type | string | expected GeoJSON type |
name | string | name of calling function |
Returns
Installation
$ npm install @turf/invariant
import { geojsonType } from "@turf/invariant";
const result = geojsonType(...);
$ npm install @turf/turf
import * as turf from "@turf/turf";
const result = turf.geojsonType(...);