How to use the vt-pbf.GeoJSONWrapper function in vt-pbf

To help you get started, we’ve selected a few vt-pbf examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github philippeauriach / vector-tiles-generator / index.js View on Github external
var geojsonvt = require('geojson-vt');
var vtpbf = require('vt-pbf');
var GeoJSONWrapper = vtpbf.GeoJSONWrapper;
var SphericalMercator = require('@mapbox/sphericalmercator');

var VectorTilesGenerator = function(options) {
  this.projection = new SphericalMercator({
    size: 256
  });
  this.pgPool = options.pgPool;
  this.cacheOptions = options.cache;
};

VectorTilesGenerator.prototype.tile = function(opts) {
  var tile = {
    x: opts.x,
    y: opts.y,
    z: opts.z
  };

vt-pbf

Serialize mapbox vector tiles to binary protobufs in javascript.

MIT
Latest version published 4 years ago

Package Health Score

74 / 100
Full package analysis

Similar packages