@northguild/gmt
Version:
Date and time library for JavaScript and TypeScript, built on TC39 Temporal: time zones, DST, business days, ISO 8601 strings in and out. Never throws.
24 lines • 1.1 kB
TypeScript
import { DeliverySchedule, Leg, ScheduleDeliveryOptions } from "../transport/calculate/scheduleDelivery.js";
/**
* The core of `etaAtZone`: an arrival instant rendered in a zone. Never throws.
*
* @returns what `etaAtZone` returns, for the same arguments
*
* @example etaAtZoneText("2024-03-15T12:00:00Z", "Asia/Tokyo") // "2024-03-15T21:00:00+09:00[Asia/Tokyo]"
*/
export declare function etaAtZoneText(arrivalUtc: string, targetZone: string): string;
/**
* The core of `transitTime`: a departure plus an exact duration. Never throws.
*
* @returns what `transitTime` returns, for the same arguments
*
* @example transitTimeText("2024-03-15T12:00:00Z", "PT2H") // "2024-03-15T14:00:00Z"
*/
export declare function transitTimeText(departure: string, duration: string): string;
/**
* The core of `scheduleDelivery`, and of `multimodalETA`: the legs chained into arrival instants.
* Never throws.
*
* @returns what `scheduleDelivery` returns, for the same arguments
*/
export declare function scheduleDeliveryValue(legs: Leg[], options?: ScheduleDeliveryOptions): DeliverySchedule | null;