Geopolitical models ready to use!
gem "geopolitical"
Nation > Region > City > Hood all with:
- Names (with i18n and sanitized version)
- ISO codes and abbreviations (Nations & Regions)
- Hierarchy (Hood.first.city.region.nation.abbr # BR)
- Languages
- Geometries
- Postal codes
- Phone codes
Two letter code: BR, DE, UK, US...
Region/Province state code: BR-SP, BR-RJ, BR-MG, US-NY, US-WA, US-CA
Areas and points.
With the help of phonie, it's now easy to two way map entities and phone codes.
Great for address validation and form pre-population.
require 'geopolitical/models'
- Nation -> Country
- Region -> State/Province
- City -> District/Microregion
- Hood -> Zone/Neighbourhood
- City -> District/Microregion
- Region -> State/Province
Each must be inside the former.
Use Geonames_local to populate data easily! "geonames_local"(https://github.com/fireho/geonames_local)
http://download.geonames.org/export/dump/ http://www.statoids.com/ubr.html
This project rocks and uses MIT-LICENSE.