Developer documentation
How Terrain Viewer is built, for contributors and the curious. Setup and structure, the URL as an API, the custom tile protocols, the historical imagery adapters, and the internals of the map and the interface.
Terrain Viewer is a client-side app, React and MapLibre GL, with no backend: every visualization is computed in the browser from the elevation tiles, and every setting lives in the URL. These pages are for anyone running it locally, embedding it, or reading its source.
- Setup: running the app, the URL as app state, the structure of the repository and its architecture. Start here.
- Tech stack and the equations behind the visualization modes.
- The URL as an API and the generated state reference: every query parameter and local setting.
- Custom protocols: the
slope://,svf://,lerc://and other tile handlers, the terrain analysis pipeline and the tile caches. - Historical imagery: Esri Wayback and Google Earth historical.
- Map and interface internals: camera sync, map bounds, layer order, draping, the product tour, coverage footprints and the demo videos.
- Advocacy, the upstream requests and indexing and SEO.