naija-districts-constituencies
v1.0.1
Published
list of all districts and constituencies in nigeria
Downloads
14
Maintainers
Readme
naija-districts-constituencies
An NPM Package that Searches for Districts and Constituencies in Nigeria
Installation
npm i naija-districts-constituencies
Usage
const area = require('naija-districts-constituencies');
Perform a search for Districts or Constituencies in Nigeria, it will return array of Districts or Constituencies with the state and District or Constituency closest to your search input
Example 1
let districts = area.searchDistricts('Abia');
console.log(districts)
// Output [{ state: "Abia, districts: [ 'Abia North', 'Abia South', 'Abia Central' ] },{ state: 'Taraba', districts: [ 'Taraba North', 'Taraba Central', 'Taraba South' ] }, .......]
Example 2
let all_districts = area.allDistricts();
console.log(all_districts)
Returns an array of all districts and Their states in Nigeria
Example 3
let consistuency = area.searchConstituency('Osun');
console.log(consistuency)
// Output [{ state: 'Osun', constituencies: [ 'Irepodun', 'Olorunda', 'Oshogbo', 'Orolu', 'Boripe', 'Ifelodun', 'Odo-Otin', 'Boluwaduro Ifedayo', 'Ila', 'Atakumnosa East', 'Atakunmosa West', 'Ilesa West', 'Ilesa East', 'Obokun Oraide', 'Ife Central', 'Ife East', 'Ife North', 'Ife South', 'Aydire','Iwo', 'Ola-Oluwa', 'Ayedaade', 'Irewole', 'Isokan', Ede North','Ede South', 'Egbedore','Ejigbo' ] }, .......]
Example 4
let all_constituencies = area.allConstituencies();
console.log(all_constituencies)
Returns an array of all Consistuencies and Their states in Nigeria
You can contact me
Facebook: Chilaka Chinedu E-mail: [email protected]
github Repo
https://github.com/Greatchinex/naija-districts-constituencies