# @terrestris/vectortiles

> A simple library that makes use of free available world-wide terrestris vectortiles in MapBox MVT format from OpenStreetMap data

Latest version **0.4.0** (published 2021-08-20) · BSD-2-Clause license · 0 weekly downloads

## Install

```sh
npm install @terrestris/vectortiles
pnpm add @terrestris/vectortiles
yarn add @terrestris/vectortiles
bun add @terrestris/vectortiles
```

## Health

**Score 20/100 (F)** — status: abandoned.

Positive: esm support; no vulnerabilities.

Warnings: low downloads; no types; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.4.0 |
| Published | 2021-08-20 |
| First published | 2018-10-24 |
| Weekly downloads | 0 |
| License | BSD-2-Clause |
| TypeScript types | none |
| Module format | ESM + CommonJS |
| Dependencies | 1 |
| Unpacked size | 77 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 5 |
| Author | terrestris GmbH & Co. KG |
| Maintainers | jansule, annarieger, terrestris-info, marcjansen, kaivolland, dnlkoch, ahennr, buehner, hwbllmnn, lukaslohoff, mholthausen, sgoetsch, jorzekowsky, simonseyock, hblitza, jweskamm, unraveler |
| Keywords | vectortiles, mvt, openlayers, mapping, geo, ol, openstreetmap |

## Links

- npm: https://www.npmjs.com/package/@terrestris/vectortiles
- Repository: https://github.com/terrestris/vectortiles
- Homepage: https://github.com/terrestris/vectortiles#readme
- Issues: https://github.com/terrestris/vectortiles/issues
- npm.io page: https://npm.io/package/@terrestris/vectortiles

## Dependencies (1)

- [ol](https://npm.io/package/ol.md) 6.6.1

## Alternatives

- [postcss-color-hex-alpha](https://npm.io/package/postcss-color-hex-alpha.md) — 6.4M weekly downloads
- [randomcolor](https://npm.io/package/randomcolor.md) — 348.0K weekly downloads
- [bows](https://npm.io/package/bows.md) — 1.3K weekly downloads
- [ep_prefer_color_scheme](https://npm.io/package/ep_prefer_color_scheme.md) — 260 weekly downloads
- [coc-yank](https://npm.io/package/coc-yank.md) — 61 weekly downloads

## Recent versions

- 0.4.0 (latest) — 2021-08-20
- 0.3.0 — 2018-10-30
- 0.2.0 — 2018-10-25
- 0.1.1 — 2018-10-25
- 0.1.0 — 2018-10-24

## README

# terrestris vectortiles
A simple library that makes use of free available world-wide terrestris vectortiles in MapBox MVT format from OpenStreetMap data.

The main method `getOSMLayer` creates an openlayers VectorTile Layer, which you
can use straight in your openlayers application.

![example](terrestris-vectortiles.png "Example")

# demo
A simple demonstration application can be found here:

https://demo.terrestris.de/democlient/index.html

# how to use
Install the module e.g. by

`npm i @terrestris/vectortiles`

Then, in your code, import as follows:
```
import terrestrisVectorTiles from '@terrestris/vectortiles';
```

Then you can create the OSM-VectorTile layer by calling
```
const layer = new terrestrisVectorTiles();
```
or with custom configuration and style:
```
const layer = new terrestrisVectorTiles({
    declutter: false,
    usePlacesLabels: false,
    style_roads: [{
        ...
    }]
});
```

---
_Source: https://npm.io/package/@terrestris/vectortiles · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
