Overview
GeoViewer is a demonstration only and not finished part of a reforestation management platform I am currently working on my free time. This sample showcases the geospatial visualization capabilities that allow users to preview and upload reforestation project areas.
Features
- Geospatial Data Visualization: Interactive map display using OpenLayers
- Multiple Format Support: Upload and process GeoJSON, KML, and KMZ files
- Project Management: Create and configure reforestation projects
- Area Analysis: Automatic calculation of area sizes for reforestation zones
Technology Stack
- Framework: SvelteKit
- Map Visualization: OpenLayers
- Data Processing:
- GeoJSON handling with @turf/turf for area calculations
- KML/KMZ parsing with @tmcw/togeojson and xmldom
- File extraction with JSZip
- Custom geometry utilities for normalization and validation
- Form Handling: sveltekit-superforms, zod validation
Getting Started
Prerequisites
Installation
# Clone the repository
git clone <repository-url>
cd geo-viewer
# Install dependencies
pnpm install
# Start the development server
pnpm dev
Usage
- Start the application with
pnpm dev
- Upload a GeoJSON or KML/KMZ file containing reforestation project areas
- View the areas on the interactive map
- Fill in project details and submit
- Watch for the results in the console; browser and server