UNPKG

361 BTypeScriptView Raw
1import { Composed } from "throwback";
2import { CommonRequest, CommonResponse } from "servie/dist/common";
3/**
4 * Create a `fetch` like interface from middleware stack.
5 */
6export declare function toFetch<T extends CommonRequest, U extends CommonResponse, A extends any[]>(middleware: Composed<T, U>, Request: new (...args: A) => T): (...args: A) => Promise<U>;