Rails Apps

Parcely okresu Jičín source on GitHub
Source on GitHub

PHP 8 · SQLite · solo · public

  • Leaflet
  • R-tree
  • GeoJSON
  • open data

All 273,893 land parcels of one Czech district, straight from the official cadastre, on a map that stays smooth. Click a parcel for its record, or find it by number. Built as an interview task; the whole point was that it must not stutter over a quarter of a million polygons.

  • Smooth over 273,893 parcels. The browser is never sent the whole district. Each pan asks for the current viewport only, answered from an R-tree index in single-digit milliseconds.
  • Detail follows the zoom. District boundaries far out, simplified geometry in the middle, full outlines up close. Worst-case viewport: about 95 ms and 400 kB gzipped.
  • The map projection, written by hand. The national grid converts to WGS84 in about sixty lines of plain PHP instead of a dependency, then checked against the cadastre's own published coordinates: 0.10–0.21 m median error over 15,774 points.
  • Simplification that doesn't break thin shapes. A fixed tolerance collapsed streams and paths into crossing lines. Capping it at a third of each ring's own width fixed all 97 broken parcels.