Skip to main content

startsLikeWkt

Whether the text starts with the name of a WKT geometry type (in any case, with or without a Z, M or ZM tag), including the curved types parseWkt does not read, or with an EWKT SRID= prefix. It says what the text is meant to be, not whether it can be read: use it to tell a damaged WKT file from a file that is something else.

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

Signature​

import { startsLikeWkt } from "@mapcairn/core";

function startsLikeWkt(text: string): boolean;

Parameters​

  • text (string)

Returns​

boolean

Source: packages/core/src/geometry/wkt.ts:149