countryjs-states-paypal v0.2.0
countryjs-states-paypal
A Node.js module that map countryjs's states or provinces to PayPal's.
Table of Contents
Install
npm install countryjs-states-paypal
Usage
To map a country's states from countryjs state or province name to PayPal's, use the following API method:
var countryjsToPaypal = require("countryjs-states-paypal")
countryjsToPaypal.find("MX", "Veracruz-Llave")
{
name: 'Veracruz'
, code: 'VER'
, countryjs: 'Veracruz-Llave'
}
And for all data, just use:
countryjsToPaypal.all()
Contributing
To contribute code to this module, please follow this workflow:
- fork the repo
make sure to install dev dependencies using
npm install --dev
Make the changes you desire
Ensure all changes have a new test in the
test/
folder, and run:npm test
After making changes in your fork, open a pull request.
Please note that if your code updates do not pass JS Standard style, mocha tests and code coverage, your PR may be rejected and you'll need to fix any issues listed in it.
Changelog
v0.1.1-v0.2 - 2019-08-09
- Add China's provinces
v0.1-v0.1.1 - 2018-03-27
- Initial release: mapping, test coverage, travis-ci, npm package
Disclaimer
This is being maintained in the contributor's free time, and as such, may contain minor errors in regards to some countries. The information included in this library is what is listed on PayPal's developer website:
If there is an error, please let me know and I will do my best to correct it.
Contributors
- Fabrice Colas fabrice.colas@gmail.com - /fabricecolas - fabricecolas.me