A fully interactive Leaflet map built with React, featuring multiple GeoJSON layers, map controls, and layer toggling functionality.
- Interactive map with Leaflet and React-Leaflet.
- Toggleable GeoJSON layers (e.g., town centers, roads, residential areas).
- Base map toggle with support for Satellite, Streets, Terrain, Hybrid, Dark, and Light.
- Map search powered by
leaflet-geosearchand OpenStreetMap, with a toggle button to show/hide the search bar. - Useful map controls:
- Mini-map
- Zoom
- Mouse position
- Scale
- Automatic zoom to fit visible layers.
- Styled with TailwindCSS for a clean, responsive UI.
git clone https://github.com/WanjikuN/Mapping.git
cd Mapping
npm installnpm run devRun all tests:
npx vitestRun tests in watch mode:
npx vitest --watchRun tests with coverage:
npx vitest --coverage