UNPKG

@oslokommune/punkt-elements

Version:

Komponentbiblioteket til Punkt, et designsystem laget av Oslo Origo

13 lines (12 loc) 622 B
import { DEFAULT_HEADER_FOOTER_URL, type THeaderFooterApi } from '../../shared-types/header-menu'; export { DEFAULT_HEADER_FOOTER_URL }; /** * Fetch and parse the Oslo kommune header/footer JSON payload. * * Throws on HTTP errors and on invalid JSON. The caller is responsible * for surfacing or hiding errors — the Lit element, for example, hides * the menu and dispatches a `data-error` event. * * `signal` lets callers abort the fetch when the component disconnects. */ export declare function fetchHeaderFooterData<IconType = string>(url?: string, signal?: AbortSignal): Promise<THeaderFooterApi<IconType>>;