{"name":"@mapbox/vector-tile","description":"Parses vector tiles","repository":{"type":"git","url":"git+https://github.com/mapbox/vector-tile-js.git"},"version":"1.3.1","license":"BSD-3-Clause","main":"index.js","dependencies":{"@mapbox/point-geometry":"~0.1.0"},"devDependencies":{"benchmark":"^1.0.0","coveralls":"~2.11.2","istanbul":"~0.3.6","mapnik":"~3.6.0","jshint":"^2.6.3","pbf":"^1.3.2","tape":"~3.5.0","eslint":"~1.00.0","eslint-config-unstyled":"^1.1.0"},"jshintConfig":{"trailing":true,"undef":true,"unused":true,"indent":4,"node":true},"scripts":{"test":"eslint lib index.js && jshint lib && tape test/parse.test.js","cov":"istanbul cover ./node_modules/.bin/tape test/parse.test.js && coveralls < ./coverage/lcov.info"},"gitHead":"58df1e9344ee64f26deee84a9f54cee11fb95ef6","bugs":{"url":"https://github.com/mapbox/vector-tile-js/issues"},"homepage":"https://github.com/mapbox/vector-tile-js#readme","_id":"@mapbox/vector-tile@1.3.1","_npmVersion":"5.6.0","_nodeVersion":"8.9.4","_npmUser":{"name":"anandthakker","email":"vestibule@anandthakker.net"},"dist":{"integrity":"sha512-MCEddb8u44/xfQ3oD+Srl/tNcQoqTw3goGk2oLsrFxOTc3dUp+kAnby3PvAeeBYSMSjSPD1nd1AJA6W49WnoUw==","shasum":"d3a74c90402d06e89ec66de49ec817ff53409666","tarball":"http://registry-npm.ywwl.com/@mapbox/vector-tile/download/@mapbox/vector-tile-1.3.1.tgz","fileCount":30,"unpackedSize":261972,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDrQ6g8bFYGzzT0WybDUc4s3/xHICrG4C8luoRsh8VaDQIhAPJ+3UePqD1ETb5KD9RjiUrYszCYOw/huUZjQfQzZwdR"}],"size":123386,"noattachment":false,"key":"/@mapbox/vector-tile/-/@mapbox/vector-tile-1.3.1.tgz"},"maintainers":[{"email":"mxn@1ec5.org","name":"1ec5"},{"email":"andrea.delrio@mapbox.com","name":"aaaandrea"},{"email":"aarthy@mapbox.com","name":"aarthykc"},{"email":"aj@mapbox.com","name":"ajashton"},{"email":"angel.kittiyachavalit@gmail.com","name":"akit"},{"email":"ali@mapbox.com","name":"alianthes"},{"email":"alice@mapbox.com","name":"aliceykuo"},{"email":"alinapaz@gmail.com","name":"alinapaz"},{"email":"aileen.s.rowan@gmail.com","name":"allierowan"},{"email":"ulsh@mapbox.com","name":"alulsh"},{"email":"amisha@mapbox.com","name":"amishas157"},{"email":"anna.petrone@mapbox.com","name":"ampetr89"},{"email":"amyleewalton@gmail.com","name":"amyleew"},{"email":"vestibule@anandthakker.net","name":"anandthakker"},{"email":"andrey@mapbox.com","name":"andygol"},{"email":"angela.navarro@mapbox.com","name":"angela.navarro"},{"email":"ansis.brammanis@gmail.com","name":"ansis"},{"email":"alex.parlato@mapbox.com","name":"aparlato"},{"email":"adarsh.pavani@mapbox.com","name":"apavani"},{"email":"andrew@mapbox.com","name":"apendleton"},{"email":"aruna@mapbox.com","name":"arunasank"},{"email":"asheemm@gmail.com","name":"asheemmamoowala"},{"email":"andrew.evans@mapbox.com","name":"atevans-mapbox"},{"email":"benjamin@mapbox.com","name":"benjamintd"},{"email":"bryan@mapbox.com","name":"bhousel"},{"email":"bhargav.kowshik@gmail.com","name":"bkowshik"},{"email":"blannon@gmail.com","name":"boblannon"},{"email":"jesse@rebounds.net","name":"boundsj"},{"email":"brendan@mapbox.com","name":"brendanmcfarland"},{"email":"bersabel.tadesse@mapbox.com","name":"brsbl"},{"email":"bruno@mapbox.com","name":"brunoabinader"},{"email":"bharata+npm@mapbox.com","name":"bsrinivasa"},{"email":"bobby@mapbox.com","name":"bsudekum"},{"email":"camilla@mapbox.com","name":"camillacaros"},{"email":"camilo.sanin@mapbox.com","name":"camilo.sanin"},{"email":"cameron@mapbox.com","name":"cammace"},{"email":"nadia.barbosa@mapbox.com","name":"captainbarbosa-mbx"},{"email":"caseymm@gmail.com","name":"caseymm"},{"email":"b.jazzy.w@gmail.com","name":"castledoor"},{"email":"charlie@mapbox.com","name":"charloyd"},{"email":"hello@chau-nguyen.de","name":"chaupow"},{"email":"chethan@mapbox.com","name":"chetangowda"},{"email":"christopher.cailleaux@gmail.com","name":"chriscx"},{"email":"chris.loer@mapbox.com","name":"chrisloer"},{"email":"christopher.knouss@mapbox.com","name":"cknouss"},{"email":"toomey.chris@gmail.com","name":"cmtoomey"},{"email":"colleen.mcginnis@mapbox.com","name":"colleenmcginnis"},{"email":"dave.prukop@mapbox.com","name":"d-prukop"},{"email":"daniel+npm@trvx.org","name":"danieljh"},{"email":"danmactough@gmail.com","name":"danmactough"},{"email":"danpat@danpat.net","name":"danpat"},{"email":"daniel.paz-soldan@mapbox.com","name":"danpaz-mb"},{"email":"dan@mapbox.com","name":"danswick"},{"email":"dana.sulit@mapbox.com","name":"dasulit"},{"email":"david.dave.clark@gmail.com","name":"davidtheclark"},{"email":"denis.koronchik@gmail.com","name":"deniskoronchik"},{"email":"duane.gearhart@mapbox.com","name":"dgearhart"},{"email":"dave@mapbox.com","name":"dhcole"},{"email":"diane.e.schulze@gmail.com","name":"dianeschulze"},{"email":"david.nesbitt@mapbox.com","name":"dnesbitt"},{"email":"damon@mapbox.com","name":"dnomadb"},{"email":"daniel.puttick@mapbox.com","name":"dputtick"},{"email":"devin.boyer@mapbox.com","name":"drboyer"},{"email":"dthompson@gmail.com","name":"dthompson"},{"email":"edgar.marca@mapbox.com","name":"edgar-marca"},{"email":"anthony.agby@mapbox.com","name":"electrostat"},{"email":"eli.fitch.prof+npm@gmail.com","name":"elifitch"},{"email":"emily@mapbox.com","name":"emilymcafee"},{"email":"dubois@mapbox.com","name":"emilymdubois"},{"email":"fischer@mapbox.com","name":"enf"},{"email":"eric.alessandrini@mapbox.com","name":"ericdeveloper"},{"email":"eric.wolfe@mapbox.com","name":"erwmbx"},{"email":"emily.chow@mapbox.com","name":"eschow"},{"email":"gokul.ganesan@mapbox.com","name":"fa7c0n"},{"email":"fabian.guerra@gmail.com","name":"fabianguerra"},{"email":"flippmoke@gmail.com","name":"flippmoke"},{"email":"hello@franka.tech","name":"franka"},{"email":"spam@freenerd.de","name":"freenerd"},{"email":"friedbunny@users.noreply.github.com","name":"friedbunny"},{"email":"rafa@mapbox.com","name":"geografa"},{"email":"ghoshkaj@gmail.com","name":"ghoshkaj"},{"email":"greg.knisely@mapbox.com","name":"gknisely"},{"email":"carol@mapbox.com","name":"gretacb"},{"email":"pablo.guardiola@mapbox.com","name":"guardiola31337"},{"email":"adam.debreczeni@mapbox.com","name":"heyadam_mapbox"},{"email":"hjudge@mapbox.com","name":"hjudge"},{"email":"ian.villeda@gmail.com","name":"ian29"},{"email":"ian@mapbox.com","name":"ianshward"},{"email":"safonov.ilya@gmail.com","name":"ilyasaf"},{"email":"ingalls@protonmail.com","name":"ingalls"},{"email":"siyu.song@gmail.com","name":"isiyu"},{"email":"info@ivovandongen.nl","name":"ivovandongen"},{"email":"hi@jacquestardie.org","name":"jacquestardie"},{"email":"jayana.charles@mapbox.com","name":"jayana"},{"email":"joe.clark@mapbox.com","name":"jc-clark"},{"email":"john.sylak-glassman@mapbox.com","name":"jcsg"},{"email":"john.firebaugh@gmail.com","name":"jfirebaugh"},{"email":"jim.martin@mapbox.com","name":"jim-martin"},{"email":"jinny.cho@mapbox.com","name":"jinnycho503"},{"email":"justyna.janczyszyn@mapbox.com","name":"jjanczyszyn"},{"email":"jordan.kiley@mapbox.com","name":"jmkiley"},{"email":"jordan.webb@mapbox.com","name":"jordanwebb"},{"email":"jothirnadh@mapbox.com","name":"jothirnadh"},{"email":"jake@jakepruitt.com","name":"jrpruit1"},{"email":"julianne@mapbox.com","name":"juliannebg"},{"email":"kara.e.mahoney@gmail.com","name":"k-mahoney"},{"email":"kai@mapbox.com","name":"kaibot3000"},{"email":"kalimar.maia@gmail.com","name":"kalimar"},{"email":"karen.ellenberger@mapbox.com","name":"karenell"},{"email":"karen@mapbox.com","name":"karenzshea"},{"email":"katherine.meng@mapbox.com","name":"katmeng"},{"email":"decorah@mapbox.com","name":"katydecorah"},{"email":"kristen.diluca@mapbox.com","name":"kdiluca"},{"email":"kelly.young@mapbox.com","name":"kellyoung"},{"email":"0o3ko0@gmail.com","name":"kepta"},{"email":"kevinkreiser@gmail.com","name":"kevinkreiser"},{"email":"kilatsat@gmail.com","name":"kilatsat"},{"email":"mail@kkaefer.com","name":"kkaefer"},{"email":"laurier@mapbox.com","name":"l-r"},{"email":"langston.smith@mapbox.com","name":"langstonsmith"},{"email":"lauren@mapbox.com","name":"lbud"},{"email":"lily@mapbox.com","name":"lily-chai"},{"email":"lauri.rustanius@mapbox.com","name":"lingoded"},{"email":"lizzie.gooding@mapbox.com","name":"lizziegooding"},{"email":"lo_benichou@protonmail.com","name":"lobenichou"},{"email":"liz.shigetoshi@mapbox.com","name":"lshig"},{"email":"lucas@lucaswoj.com","name":"lucaswoj"},{"email":"luis@mapbox.com","name":"luiswalter"},{"email":"me@lukasmartinelli.ch","name":"lukasmartinelli"},{"email":"lukasz.paczos@mapbox.com","name":"lukaspaczos"},{"email":"alex@mapbox.com","name":"lxbarth"},{"email":"lyzi@mapbox.com","name":"lyzidiamond"},{"email":"macro.shen@mapbox.com","name":"macro-shen"},{"email":"mai.nguyen@mapbox.com","name":"maikyon"},{"email":"mallorywood413@gmail.com","name":"mal-wood"},{"email":"emmanuel.sambale@gmail.com","name":"maning"},{"email":"manohar@mapbox.com","name":"manoharuss"},{"email":"accounts@mapbox.com","name":"mapbox-admin"},{"email":"sam@mapbox.com","name":"mapsam"},{"email":"mark.misener@mapbox.com","name":"markmisener"},{"email":"matt@mapbox.com","name":"mateov"},{"email":"matt.gosline@mapbox.com","name":"matt.gosline"},{"email":"matt@mattficke.com","name":"mattficke"},{"email":"mcwhittemore@gmail.com","name":"mcwhittemore"},{"email":"jeff@miccolis.net","name":"miccolis"},{"email":"mikel@groundtruth.in","name":"mikelmaron"},{"email":"ann.millspaugh@gmail.com","name":"millzpaugh"},{"email":"mollylloyd@gmail.com","name":"mollymerp"},{"email":"morgane.santos@mapbox.com","name":"morgane"},{"email":"morgan.herlocker@gmail.com","name":"morganherlocker"},{"email":"agafonkin@gmail.com","name":"mourner"},{"email":"max@mapbox.com","name":"msirenko"},{"email":"irwin@mapbox.com","name":"mtirwin"},{"email":"krishna@mapbox.com","name":"nammala"},{"email":"nat@mapbox.com","name":"natslaughter"},{"email":"nick.cordella@mapbox.com","name":"nickcordella"},{"email":"nicki@mapbox.com","name":"nickidlugash"},{"email":"nick.italiano@mapbox.com","name":"nickitaliano"},{"email":"nikinfour@gmail.com","name":"nikhilprabhakar"},{"email":"nmargolis89@gmail.com","name":"nmargolis"},{"email":"norchard24@gmail.com","name":"norchard"},{"email":"norman.barker@mapbox.com","name":"normanb"},{"email":"oindrila.gupta92@gmail.com","name":"oini"},{"email":"okorie.puryear@mapbox.com","name":"okoriep"},{"email":"olivia.brundage@mapbox.com","name":"oliikit"},{"email":"oormila@mapbox.com","name":"oormilavinod"},{"email":"laura.mooney@mapbox.com","name":"otherwiseman"},{"email":"michael.krasnyk@gmail.com","name":"oxidase"},{"email":"paige.moody@mapbox.com","name":"paigemoody"},{"email":"paul@mapbox.com","name":"pdgoodman"},{"email":"perry@mapbox.com","name":"perrygeo"},{"email":"peterqliu@gmail.com","name":"peterqliu"},{"email":"arun.planemad@gmail.com","name":"planemad"},{"email":"poornima@mapbox.com","name":"poornibadrinath"},{"email":"pratik@mapbox.com","name":"pratikyadav"},{"email":"patrick.taylor@mapbox.com","name":"pt-44"},{"email":"paul@pave4.com","name":"pveugen"},{"email":"rasagy@mapbox.com","name":"rasagy"},{"email":"ryan.clark.j@gmail.com","name":"rclark"},{"email":"randall.lee@mapbox.com","name":"rcleedev"},{"email":"johnny@johnnyray.me","name":"recursivefunk"},{"email":"rebecca.rice@mapbox.com","name":"rmrice"},{"email":"r.ragupathy85@gmail.com","name":"rumc"},{"email":"ryan.baumann@mapbox.com","name":"ryan-baumann"},{"email":"saba.elhilo2@gmail.com","name":"sabaelhilo"},{"email":"sabelo.mhlambi@mapbox.com","name":"sabzo"},{"email":"sewilhelm@gmail.com","name":"sadiew"},{"email":"abhishek@mapbox.com","name":"saikia.abhishek"},{"email":"saman@mapbox.com","name":"samanbb"},{"email":"eliane@mapbox.com","name":"samely"},{"email":"sam.fader@mapbox.com","name":"samfader"},{"email":"tlee@mapbox.com","name":"sbma44"},{"email":"scott.schultz@mapbox.com","name":"scottschultz"},{"email":"scott.farley@mapbox.com","name":"scottsfarley93"},{"email":"sean@mapbox.com","name":"sgillies"},{"email":"dane@mapbox.com","name":"springmeyer"},{"email":"srividyabharadwaj26@gmail.com","name":"srividyacb"},{"email":"tapasweni@mapbox.com","name":"tapasweni-pathak"},{"email":"tara.adiseshan@gmail.com","name":"taziam"},{"email":"tim.channell@gmail.com","name":"tcql"},{"email":"patrick@mapbox.com","name":"themarex"},{"email":"tmpsantos@gmail.com","name":"tmpsantos"},{"email":"tony.chen@mapbox.com","name":"tony-cj"},{"email":"tridip@mapbox.com","name":"tridip1931"},{"email":"tristen.brown@gmail.com","name":"tristen"},{"email":"upendra@mapbox.com","name":"upendrayadav"},{"email":"anjana.vakil@mapbox.com","name":"vakila"},{"email":"vincent.sarago@mapbox.com","name":"vincents"},{"email":"virginia@mapbox.com","name":"virginiayung"},{"email":"vladimir.kananovich@mapbox.com","name":"vladimir.kananovich"},{"email":"will@mapbox.com","name":"willwhite"},{"email":"xianny@gmail.com","name":"xianny"},{"email":"young@mapbox.com","name":"yhahn"},{"email":"msteigerwalt@gmail.com","name":"yuffster"},{"email":"alexy@codeforamerica.org","name":"yuletide"},{"email":"mully@mapbox.com","name":"zmully"},{"email":"antonio@mapbox.com","name":"zugaldia"},{"email":"zurihunter92@gmail.com","name":"zurihunter92"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/vector-tile_1.3.1_1520037808133_0.32587944848863715"},"_hasShrinkwrap":false,"readme":"# vector-tile\n\n[![build status](https://secure.travis-ci.org/mapbox/vector-tile-js.svg)](http://travis-ci.org/mapbox/vector-tile-js) [![Coverage Status](https://coveralls.io/repos/mapbox/vector-tile-js/badge.svg)](https://coveralls.io/r/mapbox/vector-tile-js)\n\nThis library reads [Mapbox Vector Tiles](https://github.com/mapbox/vector-tile-spec) and allows access to the layers and features.\n\n## Example\n\n```js\nvar VectorTile = require('@mapbox/vector-tile').VectorTile;\nvar Protobuf = require('pbf');\n\nvar tile = new VectorTile(new Protobuf(data));\n\n// Contains a map of all layers\ntile.layers;\n\nvar landuse = tile.layers.landuse;\n\n// Amount of features in this layer\nlanduse.length;\n\n// Returns the first feature\nlanduse.feature(0);\n```\n\nVector tiles contained in [serialtiles-spec](https://github.com/mapbox/serialtiles-spec)\nare gzip-encoded, so a complete example of parsing them with the native\nzlib module would be:\n\n```js\nvar VectorTile = require('vector-tile').VectorTile;\nvar Protobuf = require('pbf');\nvar zlib = require('zlib');\n\nzlib.gunzip(data, function(err, buffer) {\n    var tile = new VectorTile(new Protobuf(buffer));\n});\n```\n\n## Depends\n\n - Node.js v0.10.x or v0.8.x\n\n\n## Install\n\nTo install:\n\n    npm install @mapbox/vector-tile\n\n\n## API Reference\n\n\n### VectorTile\n\nAn object that parses vector tile data and makes it readable.\n\n#### Constructor\n\n- **new VectorTile(protobuf[, end])** &mdash;\n  parses the vector tile data contained in the given [Protobuf](https://github.com/mapbox/pbf) object,\n  saving resulting layers in the created object as a `layers` property. Optionally accepts end index.\n\n#### Properties\n\n- **layers** (Object) &mdash; an object containing parsed layers in the form of `{<name>: <layer>, ...}`,\nwhere each layer is a `VectorTileLayer` object.\n\n\n### VectorTileLayer\n\nAn object that contains the data for a single vector tile layer.\n\n#### Properties\n\n- **version** (`Number`, default: `1`)\n- **name** (`String) `&mdash; layer name\n- **extent** (`Number`, default: `4096`) &mdash; tile extent size\n- **length** (`Number`) &mdash; number of features in the layer\n\n#### Methods\n\n- **feature(i)** &mdash; get a feature (`VectorTileFeature`) by the given index from the layer.\n\n\n### VectorTileFeature\n\nAn object that contains the data for a single feature.\n\n#### Properties\n\n- **type** (`Number`) &mdash; type of the feature (also see `VectorTileFeature.types`)\n- **extent** (`Number`) &mdash; feature extent size\n- **id** (`Number`) &mdash; feature identifier, if present\n- **properties** (`Object`) &mdash; object literal with feature properties\n\n#### Methods\n\n- **loadGeometry()** &mdash; parses feature geometry and returns an array of\n  [Point](https://github.com/mapbox/point-geometry) arrays (with each point having `x` and `y` properties)\n- **bbox()** &mdash; calculates and returns the bounding box of the feature in the form `[x1, y1, x2, y2]`\n- **toGeoJSON(x, y, z)** &mdash; returns a GeoJSON representation of the feature. (`x`, `y`, and `z` refer to the containing tile's index.)\n","publish_time":1520037808251,"_cnpm_publish_time":1520037808251,"dist-tags":{"latest":"3.0.0"}}