UNPKG

@tempots/ui

Version:

Provides a higher level of renderables to help fast development with Tempo.

15 lines (14 loc) 749 B
import { HeadlessContext, Prop } from '@tempots/dom'; import { NavigationOptions } from './navigation-options'; import { LocationData } from './location-data'; export type HeadlessLocationSource = { location: Prop<LocationData>; dispose: () => void; commit: (data: LocationData, options: NavigationOptions | undefined, action: 'pushState' | 'replaceState') => void; go: (delta: number, options?: NavigationOptions) => void; back: (options?: NavigationOptions) => void; forward: (options?: NavigationOptions) => void; resolve: (url: string) => LocationData; }; export declare const isAbsoluteURL: (url: string) => boolean; export declare const makeHeadlessLocationSource: (ctx: HeadlessContext) => HeadlessLocationSource;