Create a new VectorTileEngine from a GeoJSON string.
The layer_name parameter controls the layer name embedded in the
MVT protobuf output. Defaults to "default".
Optionallayer_name: string | nullGet the number of cached tiles.
Clear the tile LRU cache.
Request a tile by z, x, y coordinates.
Returns a raw Uint8Array representing the MVT (PBF) protobuf.
If the tile is empty or out of bounds, returns an empty array.
Feature properties (name, id, class, and any other fields)
from the original GeoJSON are automatically encoded as MVT tags.
Request a tile with LRU caching (max 64 tiles).
If the tile was previously requested, returns the cached result without re-computing. Otherwise, generates the tile, caches it, and returns it.
Use clearTileCache() to evict all cached tiles.
A high-performance vector tile engine.
Creates a pre-indexed GeoJSONVT structure from a GeoJSON string, then can efficiently slice tiles by
(z, x, y). Feature properties from the original GeoJSON are preserved as MVT tags.Supports optional LRU caching via
getTileCached/clearTileCache.