Gathering detailed insights and metrics for hafas-collect-departures-at
Gathering detailed insights and metrics for hafas-collect-departures-at
Gathering detailed insights and metrics for hafas-collect-departures-at
Gathering detailed insights and metrics for hafas-collect-departures-at
Utility to collect departures, using any HAFAS client.
npm install hafas-collect-departures-at
Typescript
Module System
Min. Node Version
Node Version
NPM Version
JavaScript (100%)
Total Downloads
0
Last Day
0
Last Week
0
Last Month
0
Last Year
0
ISC License
2 Stars
44 Commits
2 Watchers
9 Branches
7 Contributors
Updated on Dec 19, 2022
Latest Version
4.0.1
Package Id
hafas-collect-departures-at@4.0.1
Unpacked Size
6.26 kB
Size
2.85 kB
File Count
5
NPM Version
8.19.3
Node Version
19.1.0
Cumulative downloads
Total Downloads
Last Day
0%
NaN
Compared to previous day
Last Week
0%
NaN
Compared to previous week
Last Month
0%
NaN
Compared to previous month
Last Year
0%
NaN
Compared to previous year
1
8
Utility to collect departures, using any HAFAS client.
1npm install hafas-collect-departures-at
1import {createVbbHafas} from 'vbb-hafas' 2import {createCollectDeps} from 'hafas-collect-departures-at' 3 4const fooStation = '900000100001' 5const hafas = createVbbHafas('my-awesome-program') 6const collectDeps = createCollectDeps(hafas.departures, { 7 departuresOpts: { 8 remarks: true, 9 products: {tram: false}, 10 }, 11}) 12const depsAtFoo = collectDeps(fooStation, Date.now()) 13 14let iterations = 0 15for await (const deps of depsAtFoo) { 16 if (++iterations > 2) break 17 console.log(deps) 18}
while
helperIf you don't like to use the async iteration syntax, there's a helper that works like a regular while
loop:
1import {createCollectDepsWhile} from 'hafas-collect-departures-at/while.js' 2 3const collectWhile = createCollectDepsWhile(vbb.departures) 4 5const shouldPick = (dep, i) => i < 10 6const deps = await collectWhile(fooStation, Date.now(), shouldPick) 7console.log(deps)
collectWhile()
returns a Promise that will resolve with an array of 10 items.
hafas-find-alternative-legs
– Given a hafas-client
journey, get alternatives for each leg from HAFAS.If you have a question or have difficulties using hafas-collect-departures-at
, please double-check your code and setup first. If you think you have found a bug or want to propose a feature, refer to the issues page.
No vulnerabilities found.
Reason
no binaries found in the repo
Reason
no dangerous workflow patterns detected
Reason
0 existing vulnerabilities detected
Reason
license file detected
Details
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
Found 0/25 approved changesets -- score normalized to 0
Reason
detected GitHub workflow tokens with excessive permissions
Details
Reason
dependency not pinned by hash detected -- score normalized to 0
Details
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
project is not fuzzed
Details
Reason
security policy file not detected
Details
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
Score
Last Scanned on 2025-06-30
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn More