New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

nextbus

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

nextbus

Node.js interface to the NextBus XML Feed

latest
Source
npmnpm
Version
0.0.7
Version published
Maintainers
1
Created
Source

nextbus-js

npm version Travis CI Build Status

Node.js interface to the NextBus XML Feed

Installation

npm install nextbus

Usage

import nextbus from 'nextbus';
// or:
// const nextbus = require('nextbus').default;

const nb = nextbus();
// or:
// const nb = nextbus({
//   host: 'webservices.nextbus.com', // optional; default is shown
//   protocol: 'http:',               // optional; default is shown
// });

nb.getAgencies().then((agencies) => {
  expect(agencies).toEqual([
    {
      regionTitle: 'California-Northern',
      tag: 'actransit',
      title: 'AC Transit',
    },
    {
      regionTitle: 'Maryland',
      tag: 'jhu-apl',
      title: 'APL',
    },
    {
      regionTitle: 'North Carolina',
      tag: 'art',
      title: 'Asheville Redefines Transit',
    },
    // ...
  ]);
});

Keywords

nextbus

FAQs

Package last updated on 27 Dec 2016

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts