Skip to content

Interface: ShapefileParts ​

Defined in: types.ts:178

The raw components of a shapefile, as produced by writeShapefile.

Properties ​

bbox ​

ts
bbox: [number, number, number, number];

Defined in: types.ts:198

Bounds of the data as [minX, minY, maxX, maxY].


cpg ​

ts
cpg: string;

Defined in: types.ts:186

Contents of the .cpg. Always "UTF-8", matching how the .dbf is written.


dbf ​

ts
dbf: Uint8Array;

Defined in: types.ts:184

The dBase attribute table, written as UTF-8.


dimensions ​

ts
dimensions: "xy" | "xym" | "xyz" | "xyzm";

Defined in: types.ts:192

Which ordinates were written.


featureCount ​

ts
featureCount: number;

Defined in: types.ts:194

Features written to the file.


fields ​

ts
fields: FieldDescriptor[];

Defined in: types.ts:200

How each property became a column, in file order.


prj? ​

ts
optional prj?: string;

Defined in: types.ts:188

Contents of the .prj. Present only when a projection was given.


shapeType ​

ts
shapeType: string;

Defined in: types.ts:190

The ESRI shape type written, e.g. Point, PolygonZ.


shp ​

ts
shp: Uint8Array;

Defined in: types.ts:180

Geometry. The main file.


shx ​

ts
shx: Uint8Array;

Defined in: types.ts:182

Index into the .shp. Not needed to read the file back, but expected by GIS software.


skippedCount ​

ts
skippedCount: number;

Defined in: types.ts:196

Input features dropped for having no geometry.

Released under the MIT License.