1.0.0 • Published 8 years ago

country-tz v1.0.0

Weekly downloads
40
License
MIT
Repository
github
Last release
8 years ago

country-tz

Install

npm install country-tz --save

or

bower install country-tz --save

Usage

var ctz = require('country-tz');
ctz.getCountries();  // return the list of the country objects
ctz.getZones();  // return the list of the timezone objects
ctz.getNameByCode('AD');  // return  'Andorra'
ctz.getCodeByName('Andorra');  // return 'AD'
ctz.getTimeZonesByCode('AD');  //return ['Europe/Andorra']
ctz.getCodesByTimeZone('Europe/Andorra');  //return ['AD']
  • return undefined if invalid param is given.