{"name":"pmtiles","version":"0.1.0","author":{"name":"Brandon Liu"},"license":"BSD-3-Clause","_id":"pmtiles@0.1.0","homepage":"https://github.com/protomaps/pmtiles","dist":{"shasum":"5e4ac31f158698f20d7e080afd6e8a269222347e","tarball":"http://registry-npm.ywwl.com/pmtiles/download/pmtiles-0.1.0.tgz","fileCount":3,"integrity":"sha512-mBafuJO5tDPVHItMp/pzajSVUzm9GiF4C3j8z344h56oP/mrYw0g50Yz1OHHu3K4gj6idnb9Iet3UrQ3VeImiQ==","signatures":[{"sig":"MEUCIQDp8tTabM16WOzwsapXTTOjWmdnc8Kso6g762bSjA/YmQIgUpZKTg49gXo5JrY8IN0Us6+6FtwQkJABl1nq7MnqhHE=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":14225,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.13\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJgiiHKCRA9TVsSAnZWagAA0BIP/RDRZBR9kqa1/rhm/6s1\npWVZWGBadyibjzuEcDiH0H3TH/u1u86EkfIqOgnfwDLBxMbBA+T5N5JUGdm3\nHO+qwZE3kzUCwJrpo3eWTAQ29v8GXhHSh5LtmIih99vQtYjR6vMozqhTtrHy\ngUHVESkwoNaJrwxSYGYBJeZplG23qJUCiQ1Fr6TvgVi+xnHE8hWqoNsSDRzX\nF6VKGRkYymtSRgTY+mC9cJP44uxmvqxUvgElKo3tXVpzyut/SX/V5wyzZUw4\n0bbnnbxSnZuEWPEoBdkKQBRFAdx05++BSrBUTEzBMAT4OIfb66FJ3iM9l0nK\nRoPY0Os7kiYzw75XoOKauWQWBoGMr4XROs0AZzSSSqfAfH+bXdgLvGSDNkBX\nhjQufOdVvq9wZr/K1gl/MnhuMoSQkE0RQZaskssH51SH9ijA9eOK1dtxJzGv\n5liSz3wYUpybSEZtpDitm9mKeYNZmscXExVWR6M2bTTShvPJlcOiOXGkbHJN\n10sKwVaUZMI5Qnp051lmEQLpHezM01Ve7iT60sBKECbGhxVZYqKnQJeKJR0C\nu03xhoHst4Ryfk4QQYi/cFj3/fc9NkqtAxkUNa2fucX+odIz6xntpPaTeqGQ\nXiRjxI+0JZ5CNHCUhy+pTlpvE9bdfwA7fx0M3/zZUbpZBR+0C9TlooaMmxD/\nJ7LX\r\n=XNz8\r\n-----END PGP SIGNATURE-----\r\n","size":3606,"noattachment":false,"key":"/pmtiles/-/pmtiles-0.1.0.tgz"},"main":"index","unpkg":"index.js","module":"index.mjs","scripts":{"test":"echo \"Error: no test specified\" && exit 1","build":"esbuild index.mjs --outfile=index.js --target=es2015 --global-name=pmtiles --format=iife"},"_npmUser":{"name":"bdon","email":"bdon@bdon.org"},"jsdelivr":"index.js","_npmVersion":"6.14.8","description":"PMTiles archive decoder for browsers","directories":{},"_nodeVersion":"14.15.0","_hasShrinkwrap":false,"devDependencies":{"esbuild":"^0.11.14"},"_npmOperationalInternal":{"tmp":"tmp/pmtiles_0.1.0_1619665353620_0.5080630731961937","host":"s3://npm-registry-packages"},"readme":"# PMTiles for Browsers + NodeJS\n\nSee the [JavaScript API docs](https://pmtiles.io/typedoc/)\n\nthe [PMTiles](https://www.npmjs.com/package/pmtiles) package can be included via script tag or ES6 module:\n\n```html\n <script src=\"https://unpkg.com/pmtiles@<VERSION>/dist/pmtiles.js\"></script>\n```\n\nAll the PMTiles exports are available under the global `pmtiles` variable e.g. `pmtiles.PMTiles`.\n\nAs an ES6 module: `npm add pmtiles`\n\n```js\nimport { PMTiles } from \"pmtiles\";\n```\n\n### Leaflet: Raster tileset\n\nExample of a raster PMTiles archive displayed in Leaflet:\n\n```js\nimport { PMTiles, leafletRasterLayer } from \"pmtiles\";\nconst p = new PMTiles('example.pmtiles')\nleafletRasterLayer(p,{attribution:'© <a href=\"https://openstreetmap.org\">OpenStreetMap</a>'}).addTo(map)\n````\n\n[Live example](https://pmtiles.io/examples/leaflet.html) | [Code](https://github.com/protomaps/PMTiles/blob/main/js/examples/leaflet.html)\n\n### Leaflet: Vector tileset\n\nSee [protomaps-leaflet](https://github.com/protomaps/protomaps-leaflet)\n\n## MapLibre GL JS\n\nExample of a PMTiles archive displayed in MapLibre GL JS:\n\n```js\nimport { Protocol } from \"pmtiles\";\nlet protocol = new Protocol();\nmaplibregl.addProtocol(\"pmtiles\",protocol.tile);\nvar style = {\n\"version\": 8,\n\"sources\": {\n    \"example_source\": {\n        \"type\": \"vector\",\n        \"url\": \"pmtiles://https://example.com/example.pmtiles\",\n        \"attribution\": '© <a href=\"https://openstreetmap.org\">OpenStreetMap</a>'\n    ...\n```\n\n[Live example](https://pmtiles.io/examples/maplibre.html) | [Code](https://github.com/protomaps/PMTiles/blob/main/js/examples/maplibre.html)\n\n# CORS\n\nSee the [Protomaps Docs on Cloud Storage](https://protomaps.com/docs/pmtiles/cloud-storage) for uploading and configuring CORS for Cloudflare R2, Amazon S3, Google Cloud Storage and more.\n","publish_time":1619665353775,"maintainers":[{"name":"bdon","email":"bdon@bdon.org"}],"_cnpm_publish_time":1619665353775,"dist-tags":{"beta":"3.0.0-alpha.2","latest":"4.5.0"}}