Skip to content

NavigationManager

Import

js
import { NavigationManager } from '@gebeta/js/navigation';

Methods

start(route, options, locationProvider)

ts
start(
  route: RouteData,
  options: { userId: string; role: string },
  locationProvider: ILocationProvider
): void

stop()

ts
stop(): void

isNavigating()

ts
isNavigating(): boolean

getCurrentStepIndex()

ts
getCurrentStepIndex(): number

on(event, callback) / off(event, callback)

ts
on(event: 'progress' | 'offroute' | 'arrive', callback: Function): void

Events

EventPayloadDescription
progressProgressEventFired on each location update
offrouteUser has deviated from the route
arriveUser has reached the destination