Logo Lanfrica

derrick-nuby/Rwanda-Geo-Structure

Domaine:

geospatial

Type de record:

software
Créateur:
der
Hôte:
Rwanda Geo Structure is a JavaScript library designed to simplify the process of obtaining local Rwandan administrative divisions. This app allows developers to easily integrate a form into their web applications, enabling users to select various administrative divisions such as country, province, district, sector, cell, and village. # Rwanda Geo Structure Rwanda Geo Structure is a comprehensive JavaScript package that provides easy access to Rwanda's administrative divisions. It allows developers to retrieve and work with data about provinces, districts, sectors, cells, and villages in Rwanda, streamlining the process of collecting and managing location-based data for applications focused on Rwanda. ## Table of Contents - Installation - Usage - Documentation - Available Functions - contributing - License ## Installation To install the Rwanda Geo Structure package, run the following command in your project directory: ```bash npm install rwanda-geo-structure ``` or if you're using Yarn: ```bash yarn add rwanda-geo-structure ``` ## Usage Import the functions you need: ```javascript import { getProvinces, getDistrictsByProvince, search } from "rwanda-geo-structure"; // Get all provinces const provinces = getProvinces(); // Search for locations (NEW!) const results = search('Kigali'); // Returns array of SearchEntry objects with province, district, sector, cell, and village data // Multi-word search (finds locations matching ALL words) const specific = search('Kigali Gasabo'); ``` ## Documentation For detailed usage instructions, examples, and API reference, please visit our comprehensive documentation: Rwanda Geo Structure Documentation ## Available Functions Here's a summary of the available functions in the rwanda-geo-structure package: - getCountry(): Returns the country name (always "Rwanda"). - getProvinces(): Retrieves all provinces in Rwanda. - getDistricts(): Retrieves all districts in Rwanda. - getDistrictsByProvince(province): Retrieves all districts within a specified province. - getSectors(): Retrieves all sectors in Rwanda. - getSectorsByDistrict(province, district): Retrieves all sectors within a specified district. - getCells(): Retrieves all cells in Rwanda. - getCellsBySector(province, district, sector): Retrieves all cells within a specified …