{"name":"@maplibre/mlt","version":"0.0.1-alpha.6","keywords":["maplibre","gis","vector"],"license":"(MIT OR Apache-2.0)","_id":"@maplibre/mlt@0.0.1-alpha.6","maintainers":[{"name":"maplibreorg","email":"board@maplibre.org"}],"homepage":"https://github.com/maplibre/maplibre-tile-spec/#readme","bugs":{"url":"https://github.com/maplibre/maplibre-tile-spec/issues"},"dist":{"shasum":"e8ba002a58886a44b1e6f65515a950a5dd4f1924","tarball":"http://registry-npm.ywwl.com/@maplibre/mlt/download/@maplibre/mlt-0.0.1-alpha.6.tgz","fileCount":215,"integrity":"sha512-TVSiyYQcrEqy5+DV/RENAh4WhI4GcyMU3gGbzbDPC14pOHdA8fkq6ojKsInlvvxX41lUg3Ky0SPEwEgQmuZtfQ==","signatures":[{"sig":"MEQCICgEUaLfI6YOdwwYlLotrXS8cjEaluPLnIWYBTM6EioxAiB+wkaJo/48EtrNnXPeVE37iqFUvqtkSi2QlpmNjNb0Dw==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":1276114,"size":115491,"noattachment":false,"key":"/@maplibre/mlt/-/@maplibre/mlt-0.0.1-alpha.6.tgz"},"main":"dist/mlt.js","types":"dist/index.d.ts","gitHead":"c8a0baf3ec0ca7e944ed51510210299121091d7f","scripts":{"lint":"eslint --max-warnings=0 --fix --ext .ts src bench test","test":"jest","build":"tsc","serve":"http-server .","bundle":"webpack","format":"prettier --write \"**/*.ts\"","prepare":"npm run generate","generate":"npx buf generate ../spec/schema/mlt_tileset_metadata.proto && node -e \"const fs=require('fs'); const path=require('path'); const dir=path.join('src','metadata','tileset'); fs.renameSync(path.join(dir,'mlt_tileset_metadata_pb.ts'), path.join(dir,'tilesetMetadata.g.ts'))\"","test:esm":"node --experimental-vm-modules ./node_modules/.bin/jest","serve:data":"http-server ../test/data --cors","serve:gzip":"http-server ../test/data -g --cors","serve:data2":"node test/server/dataServer.js ../../../test/data","benchmark:decoding":"node dist/benchmark/transcoding/transcodingUserSession.js","benchmark:filtering":"node dist/benchmark/data-access/filteringUserSession.js"},"_npmUser":{"name":"maplibreorg","email":"board@maplibre.org"},"repository":{"url":"git+https://github.com/maplibre/maplibre-tile-spec.git","type":"git"},"_npmVersion":"10.2.3","description":"This package contains a JavaScript decoder for the experimental MapLibre Tile (MLT) vector tile format.","directories":{},"_nodeVersion":"20.10.0","dependencies":{"bitset":"^5.1.1","@bufbuild/protobuf":"^1.10.0"},"_hasShrinkwrap":false,"devDependencies":{"nyc":"^17.0.0","pbf":"^3.3.0","cors":"^2.8.5","jest":"^29.5.0","earcut":"^3.0.1","eslint":"^8.57.1","fflate":"^0.8.2","semver":"^7.6.3","varint":"^6.0.0","codegen":"^0.1.0","express":"^4.21.1","ts-jest":"^29.2.5","ts-node":"^10.9.2","webpack":"^5.96.1","prettier":"^3.3.3","benchmark":"^2.1.4","ts-loader":"^9.5.1","bytebuffer":"^5.0.1","typescript":"5.5.4","@types/jest":"^29.5.13","@types/node":"^20.14.12","body-parser":"^1.20.3","http-server":"^14.1.1","webpack-cli":"^5.1.4","@bufbuild/buf":"^1.34.0","@types/earcut":"^3.0.0","@types/varint":"^6.0.3","@types/benchmark":"^2.1.2","@types/bytebuffer":"^5.0.49","@mapbox/vector-tile":"^1.3.1","clean-webpack-plugin":"^4.0.0","@bufbuild/protoc-gen-es":"^1.10.0","@typescript-eslint/parser":"^7.16.1","jest-matcher-deep-close-to":"^3.0.2","@maplibre/maplibre-gl-style-spec":"^20.4.0","@typescript-eslint/eslint-plugin":"^7.16.1"},"_npmOperationalInternal":{"tmp":"tmp/mlt_0.0.1-alpha.6_1760550866259_0.431223532078407","host":"s3://npm-registry-packages-npm-production"},"readme":"# maplibre-tile-spec\n\nThis package contains a JavaScript encoder and decoder for the experimental MapLibre Tile (MLT) vector tile format.\n\n## Install\n\n`npm install @maplibre/mlt`\n\n## Quickstart\n\n### Decode a tile\n\n```js\nimport { decodeTile } from '@maplibre/mlt';\n\nconst data = fs.readFileSync(tilePath);\nconst tile = decodeTile(data);\n```\n\n### Encode a tile\n\n```ts\nimport { encodeTile, type Layer } from '@maplibre/mlt';\n\nconst layers: Layer[] = [\n    {\n        name: 'places',\n        features: [\n            {\n                id: 1,\n                geometry: { type: 'Point', coordinates: [10, 20] },\n                properties: { name: 'Example' },\n            },\n        ],\n    },\n];\n\nconst data = encodeTile(layers);\n```\n\n## Contents\n\n### Code\n\nCode is in `src/`.\n\n### Tests\n\nTests are in `test/unit/`. Run tests by running `npm run test`.\ncurrently not integrated\n","publish_time":1760550866483,"_cnpm_publish_time":1760550866483,"dist-tags":{"latest":"1.3.0","next":"0.0.1-alpha.12"}}