UNPKG

nuxt-kql

Version:

Kirby's Query Language API for Nuxt

14 lines (13 loc) 619 B
import type { NitroFetchOptions } from 'nitropack'; export type KirbyFetchOptions = Pick<NitroFetchOptions<string>, 'onRequest' | 'onRequestError' | 'onResponse' | 'onResponseError' | 'query' | 'headers' | 'method' | 'body' | 'retry' | 'retryDelay' | 'retryStatusCodes' | 'timeout'> & { /** * Language code to fetch data for in multi-language Kirby setups. */ language?: string; /** * Cache the response between function calls for the same path. * @default true */ cache?: boolean; }; export declare function $kirby<T = any>(path: string, opts?: KirbyFetchOptions): Promise<T>;