furkot-trip
Adds stops to Furkot - online trip planner.
Installation
Install with npm:
$ npm install --save furkot-trip
Install with component(1):
$ component install code42day/furkot-trip
API
.plan(stops)
Redirects user to Furkot website and adds stops to an existing trip or a new trip. If user is not logged in she will be asked to sign in before selecting a trip (or creating a new one).
stops
is an Array
of objects with name
, description
, coordinates
(lat, lon), url
and
duration
(in milliseconds). Only name
and coordinates
are required.
var furkotTrip = ;var stops = name: 'Time Square' coordinates: lat: 407577 lon: -739857 name: 'Metropolitan Museum' coordinates: lat: 407789 lon: -739637 ;var nyTrip = ; nyTrip;
.getUrl(stops)
Returns URL to Furkot with stops encoded in the query part. The URL will redirect user to Furkot and add stops to an existing trip or a new trip.
See how it works with Liftie.
License
MIT