# vbb-translate-ids

> Translate VBB IDs from 9-digit to 12-digit and reverse.

Latest version **4.0.0** (published 2020-01-29) · ISC license · 0 weekly downloads

## Install

```sh
npm install vbb-translate-ids
pnpm add vbb-translate-ids
yarn add vbb-translate-ids
bun add vbb-translate-ids
```

## 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 | 4.0.0 |
| Published | 2020-01-29 |
| First published | 2016-12-11 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Node | >=6 |
| Dependencies | 0 |
| Unpacked size | 2.9 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 1 |
| Author | Jannis R |
| Maintainers | derhuerst |
| Keywords | vbb, stations, ids, new, ids, international |

## Links

- npm: https://www.npmjs.com/package/vbb-translate-ids
- Repository: https://github.com/derhuerst/vbb-translate-ids
- Issues: https://github.com/derhuerst/vbb-lines/issues-at
- npm.io page: https://npm.io/package/vbb-translate-ids

## 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

- 4.0.0 (latest) — 2020-01-29
- 3.1.0 (next) — 2017-09-20
- 3.0.0 — 2017-09-20
- 2.0.0 — 2016-12-11

## README

# vbb-translate-ids

**Translate VBB IDs from 9-digit to 12-digit and reverse.**

[![npm version](https://img.shields.io/npm/v/vbb-translate-ids.svg)](https://www.npmjs.com/package/vbb-translate-ids)
[![build status](https://img.shields.io/travis/derhuerst/vbb-translate-ids.svg)](https://travis-ci.org/derhuerst/vbb-translate-ids)
![ISC-licensed](https://img.shields.io/github/license/derhuerst/vbb-translate-ids.svg)
[![gitter channel](https://badges.gitter.im/derhuerst/vbb-rest.svg)](https://gitter.im/derhuerst/vbb-rest)


## Installing

```shell
npm install vbb-translate-ids
```


## Usage

```js
const {to12Digit, to9Digit} = require('vbb-translate-ids')

assert.strictEqual(to12Digit('900003201'), '900000003201')
assert.strictEqual(to9Digit('900000003201'), '900003201')
```

If `to12Digit`/`to9Digit` don't know how to translate the ID, they will just return it.


## Contributing

If you **have a question**, **found a bug** or want to **propose a feature**, have a look at [the issues page](https://github.com/derhuerst/vbb-translate-ids/issues).

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