@hyper-fetch/react
Version:
React hooks and utils for the hyper-fetch
11 lines • 577 B
TypeScript
import { RequestInstance } from '@hyper-fetch/core';
import { UseSubmitOptionsType, UseSubmitReturnType } from '.';
/**
* This hook aims to mutate data on the server. Unlike useFetch, it does not fire automatically -
* call the returned `submit` function to trigger the request (e.g., on button click).
* @param request
* @param options
* @returns
*/
export declare const useSubmit: <RequestType extends RequestInstance>(request: RequestType, options?: UseSubmitOptionsType<RequestType>) => UseSubmitReturnType<RequestType>;
//# sourceMappingURL=use-submit.hooks.d.ts.map