# geometryLength

The length of a geometry in metres, along the ground. A line is its length,
a polygon its perimeter, holes included, and a collection the sum of its
members. A point, and any empty geometry, has no length. It sums the same
per-line measure as `measureLineDistance`, so the two agree.

This is a function exported by `@mapcairn/core`, checked against version 0.2.0.

## Signature

```ts
import { geometryLength } from "@mapcairn/core";
 
function geometryLength(input: GeometryInput): number;
```

## Parameters

- `input` (`GeometryInput`)

## Returns

`number`

## Throws

- `GeometryError` of kind `invalid` for a malformed geometry.

## See also

- [`GeometryInput`](https://docs.mapcairn.com/api/core/GeometryInput.md)

Source: [packages/core/src/geometry/queries.ts:191](https://github.com/MapCairn/mapcairn/blob/main/packages/core/src/geometry/queries.ts#L191)
