Skip to content

Provides registry records for regions, cities, provinces and barangays in the Philippines.

License

Notifications You must be signed in to change notification settings

tenshiAMD/phil_locator

Repository files navigation

Phil Locator

Gem Version Known Vulnerabilities FOSSA Status

Description

Provides registry records in the Philippines which the data came from PSA (PSGC).

  • regions
  • cities
  • provinces
  • barangays
  • island_group
  • municipality
  • districts (Metro Manila Only)
  • sub_municipality (Metro Manila Only)

Installation

In Gemfile:

gem "phil_locator", "~> 1.3.0"

Or, from the command line:

gem install phil_locator -v "~> 1.3.0"

Usage

# Regions
PhilLocator::Region.all

# Provinces
PhilLocator::Province.all

# Cities
PhilLocator::City.all

# Barangays
PhilLocator::Barangay.all

Configuration

Create an initializer phil_locator.rb to configure the options, here's a sample provided below

PhilLocator.configure do |config|
    # This overrides the default data directory
    config.data_root_path = Rails.root.join("datasets").to_s
end

Copyright

This project is released under the MIT license.

License

FOSSA Status

About

Provides registry records for regions, cities, provinces and barangays in the Philippines.

Topics

Resources

License

Code of conduct

Security policy

Stars

Watchers

Forks

Sponsor this project

 

Packages

No packages published

Languages