# get-tz

> Get time zone data from IANA time zone database

Latest version **1.0.0** (published 2016-06-15) · MIT license · 0 weekly downloads

## Install

```sh
npm install get-tz
pnpm add get-tz
yarn add get-tz
bun add get-tz
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.0 |
| Published | 2016-06-15 |
| First published | 2016-06-15 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 0 |
| Author | Shinnosuke Watanabe |
| Maintainers | shinnn |
| Keywords | request, get, fetch, extract, parse, latest, tz, time, zone, zones, timezone, timezones, list, data, database, iana, code, country, country-code, coordinate, coordinates, id, identifier, identifiers |

## Links

- npm: https://www.npmjs.com/package/get-tz
- Repository: https://github.com/shinnn/get-tz
- Homepage: https://github.com/shinnn/get-tz#readme
- Issues: https://github.com/shinnn/get-tz/issues
- npm.io page: https://npm.io/package/get-tz

## Dependencies (2)

- [get-zonetab](https://npm.io/package/get-zonetab.md) ^1.0.0
- [parse-zonetab](https://npm.io/package/parse-zonetab.md) ^1.0.0

## Alternatives

- [@sindresorhus/slugify](https://npm.io/package/@sindresorhus/slugify.md) — 3.7M weekly downloads
- [solid-js](https://npm.io/package/solid-js.md) — 2.7M weekly downloads
- [expo-glass-effect](https://npm.io/package/expo-glass-effect.md) — 2.5M weekly downloads
- [nanoassert](https://npm.io/package/nanoassert.md) — 780.8K weekly downloads
- [@ffmpeg/ffmpeg](https://npm.io/package/@ffmpeg/ffmpeg.md) — 529.5K weekly downloads

## Recent versions

- 1.0.0 (latest) — 2016-06-15
- 0.0.0 — 2016-06-15

## README

# get-tz

[![NPM version](https://img.shields.io/npm/v/get-tz.svg)](https://www.npmjs.com/package/get-tz)
[![Build Status](https://travis-ci.org/shinnn/get-tz.svg?branch=master)](https://travis-ci.org/shinnn/get-tz)
[![Coverage Status](https://img.shields.io/coveralls/shinnn/get-tz.svg)](https://coveralls.io/github/shinnn/is-gist-starred?branch=master)
[![Dependency Status](https://david-dm.org/shinnn/get-tz.svg)](https://david-dm.org/shinnn/get-tz)
[![devDependency Status](https://david-dm.org/shinnn/get-tz/dev-status.svg)](https://david-dm.org/shinnn/get-tz#info=devDependencies)

A [Node](https://nodejs.org/) module to get time zone data form [IANA Time Zone Database](https://www.iana.org/time-zones)

```javascript
const getTz = require('get-tz');

getTz().then(rows => {
  rows; /* => [
    {
      countryCode: 'AD',
      coordinate: {
        latitude: {sign: '+', degree: 42, minute: 30},
        longitude: {sign: '+', degree: 1, minute: 31}
      },
      id: 'Europe/Andorra'
    },
    {
      countryCode: 'AE',
      coordinate: {
        latitude: {sign: '+', degree: 25, minute: 18},
        longitude: {sign: '+', degree: 55, minute: 18}
      }
      id: 'Asia/Dubai'
    },
    ...
  ] */  
})
```

## Installation

[Use npm.](https://docs.npmjs.com/cli/install)

```
npm install get-tz
```

## API

```javascript
const getTz = require('get-tz');
```

### getTz([*options*])

*options*: `Object` (directly passed to [`Request`](https://github.com/request/request#requestoptions-callback))  
Return: [`Promise`](http://www.ecma-international.org/ecma-262/6.0/#sec-promise-constructor)

It gets the latest [`zone.tab`](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones) file form <https://www.iana.org/time-zones> and returns a promise for an array of [parsed](https://github.com/shinnn/parse-zonetab) TSV data.

## License

Copyright (c) 2016 [Shinnosuke Watanabe](https://github.com/shinnn)

Licensed under [the MIT License](./LICENSE).

---
_Source: https://npm.io/package/get-tz · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
