Philippines zip code directory
npm install zipcodes-ph)




Philippines zip code directory.
Install via npm:
``bash`
$ npm install --save zipcodes-ph
Browser builds are also available inside the build directory or in unpkg.com.
NodeJS:
`js
const zipcodes = require('zipcodes-ph');
zipcodes.find(6000); // 'Cebu City'
zipcodes.reverse('Cebu City'); // 6000
`
Browser:
`html`
`jszipcodesPH
// global variable is exposed
zipcodesPH.find(6000); // 'Cebu City'
zipcodesPH.reverse('Cebu City'); // 6000
`
- find(zipcode)
- zipcode _(Number|String)_: The zip code that will be resolved into a location name.
- possible return values:
- _String_ if one location with the zip code is found.
- _Array_ if multiple locaitons with the zip code are found.
- _null_ if no locations with the zip code are found.
- reverse(location)
- location` _(String)_: The name of the location that will be resolved into a zip code.
- possible return values:
- _Number_ if zip code for the location is found.
- _null_ if zip code for the location is not found.
MIT License