UNPKG

sgod-library-frontend

Version:
23 lines (22 loc) 770 B
type CustomOptions = Omit<RequestInit, "method"> & { baseUrl?: string | undefined; }; declare const http: { get<Response>(url: string, options?: Omit<CustomOptions, "body"> | undefined): Promise<{ status: number; payload: Response; }>; post<Response>(url: string, body: any, options?: Omit<CustomOptions, "body"> | undefined): Promise<{ status: number; payload: Response; }>; put<Response>(url: string, body: any, options?: Omit<CustomOptions, "body"> | undefined): Promise<{ status: number; payload: Response; }>; delete<Response>(url: string, options?: Omit<CustomOptions, "body"> | undefined): Promise<{ status: number; payload: Response; }>; }; export default http;