5.13.0 • Published 2 years ago

vbb-lines v5.13.0

Weekly downloads
5
License
ISC
Repository
github
Last release
2 years ago

vbb-lines 🚏

A collection of all lines (and their stations) of the Berlin Brandenburg public transport service (VBB), computed from open GTFS data.

npm version ISC-licensed support me via GitHub Sponsors chat with me on Twitter

Installing

npm install vbb-lines

Usage

The npm package contains data in the Friendly Public Transport Format.

{
	type: 'line',
	id: '17519_400',
	name: 'U55',
	operator: '796',
	mode: 'train',
	product: 'subway',
	variants: [
		['070201054601', '070201054501', '070201054401'], // station ids
		['070201054401', '070201054501', '070201054601']
	]
}
const lines = require('vbb-lines')

lines(true, '15296_700').then(console.log) // query a single line
lines({mode: 'bus'}).on('data', console.log) // filter lines
lines('all').on('data', console.log)

If you want the data as JSON, use require('vbb-lines/data.json').

API

lines([promised], [pattern])

If promised is true, a Promise will be returned, resolving with an array of results.

Otherwise, a stream in object mode will be returned, emitting one line at a time.

pattern can be one of the following:

  • a line ID, like '15296_700'
  • 'all'
  • an object like {mode: 'bus', agencyId: '47'}, with each property being mandatory

Contributing

If you have a question, found a bug or want to propose a feature, have a look at the issues page.

5.13.0

2 years ago

5.12.0

2 years ago

5.11.0

2 years ago

5.10.0

2 years ago

5.9.0

2 years ago

5.8.0

2 years ago

5.7.0

2 years ago

5.6.0

2 years ago

5.5.0

2 years ago

5.4.0

2 years ago

5.3.0

4 years ago

5.2.0

4 years ago

5.1.0

4 years ago

5.0.0

4 years ago

4.12.0

4 years ago

4.11.1

5 years ago

4.11.0

6 years ago

4.10.0

6 years ago

4.9.0

7 years ago

4.8.0

7 years ago

4.7.0

7 years ago

4.6.0

7 years ago

4.5.0

7 years ago

4.4.0

8 years ago

4.3.0

8 years ago

4.2.0

8 years ago

4.1.0

8 years ago

4.0.0

8 years ago

4.0.0-alpha.1

8 years ago

3.11.0

8 years ago

3.10.0

8 years ago

3.9.0

9 years ago

3.8.0

9 years ago

3.7.0

9 years ago

3.6.0

9 years ago

3.5.0

9 years ago

3.4.1

9 years ago

3.4.0

9 years ago

3.3.1

9 years ago

3.3.0

9 years ago

3.2.0

9 years ago

3.1.0

9 years ago

3.0.0

9 years ago

2.3.0

9 years ago

2.2.0

9 years ago

2.1.0

10 years ago

2.0.1

10 years ago

2.0.0

10 years ago

1.2.0

10 years ago

1.1.0

10 years ago

1.0.0

10 years ago

0.2.0

10 years ago

0.1.0

10 years ago