UNPKG

@resourge/react-fetch

Version:

[![License](https://img.shields.io/badge/License-MIT-blue.svg)](LICENSE)

18 lines (17 loc) 704 B
/** * react-fetch v1.41.3 * * Copyright (c) resourge. * * This source code is licensed under the MIT license found in the * LICENSE.md file in the root directory of this source tree. * * @license MIT */ /** * When deps change all useFetch's (in mounted components and with deps) will trigger. * Serves to remove the need to put the same dependency on all useFetch's * @param deps - Dependencies that will trigger requests on useFetch's in components mounted * @param filterRequest - To filter all request not need by this "deps". `id` is equal to useFetch config id. */ export declare const useFetchOnDependencyUpdate: <T = any[]>(deps: T, filterRequest?: (id: string) => boolean) => void;