TE
TechEcho
Home24h TopNewestBestAskShowJobs
GitHubTwitter
Home

TechEcho

A tech news platform built with Next.js, providing global tech news and discussions.

GitHubTwitter

Home

HomeNewestBestAskShowJobs

Resources

HackerNews APIOriginal HackerNewsNext.js

© 2025 TechEcho. All rights reserved.

Show HN: geojson-shave, a tool for reducing the size of GeoJSON files

1 pointsby ben-n933about 1 year ago
geojson-shave reduces the size of GeoJSON files by:<p>- Truncating latitude&#x2F;longitude coordinates to the specified decimal places.<p>- Eliminating unnecessary whitespace.<p>- (Optionally) replacing the properties key&#x27;s value with null&#x2F;empty dictionary.

1 comment

matteasonabout 1 year ago
Have you thought about adding a simplification algorithm such as Ramer-Doublas-Peucker [0] or Visvalingam–Whyatt [1]? I&#x27;ve used <a href="https:&#x2F;&#x2F;mapshaper.org&#x2F;" rel="nofollow">https:&#x2F;&#x2F;mapshaper.org&#x2F;</a> to do GeoJSON path simplification before and those seem to work very well. For applications which want to maintain path accuracy while reducing the number of waypoints that may be more effective than truncating the decimal places<p>[0] <a href="https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Ramer%E2%80%93Douglas%E2%80%93Peucker_algorithm" rel="nofollow">https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Ramer%E2%80%93Douglas%E2%80%93...</a><p>[1] <a href="https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Visvalingam%E2%80%93Whyatt_algorithm" rel="nofollow">https:&#x2F;&#x2F;en.wikipedia.org&#x2F;wiki&#x2F;Visvalingam%E2%80%93Whyatt_alg...</a>