TomTom Maps for JavaScript
    Preparing search index...

    Type Alias RouteProgress

    RouteProgress: RouteProgressPoint[]

    Array of progress points along the route path.

    Provides distance and time information at key points along the route. This field is included when extendedRouteRepresentations is requested.

    • Always contains entries for the first and last points in the route
    • Progress for intermediate points can be linearly interpolated between explicitly defined points
    • Use the Haversine formula for distance calculations between points
    const progress: RouteProgress = [
    { pointIndex: 0, travelTimeInSeconds: 0, distanceInMeters: 0 },
    { pointIndex: 50, travelTimeInSeconds: 120, distanceInMeters: 2500 },
    { pointIndex: 100, travelTimeInSeconds: 300, distanceInMeters: 5000 }
    ];