A utility to minify GeoJSON files by encoding geometries using delta and zigzag encoding, reducing file size by 2-4 times. Version 0.1.1 (last release appears to be stable). It provides both a CLI and an API for integration. Differentiator: simple encoding approach optimized for GeoJSON, unlike general compression tools like gzip. No recent updates; minimal maintenance.
npm install geojson-minifierNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Instantiate minifier with precision, pack a GeoJSON object, then unpack it back to original.
Always use the same precision value when packing and unpacking.
Use JSON.stringify(packed) to write to file.
Use npx geojson-minifier or install globally.
Test with your specific GeoJSON structure before production use.
Use ES module import: import GeojsonMinifier from 'geojson-minifier';
Parse JSON string first: JSON.parse(geojsonString).
new GeojsonMinifier({ precision: 6 }) or any integer.No dependency data recorded yet.