import { DependencyList } from 'react'; import type { DependenciesComparator } from '../types'; export declare type EffectCallback = (...args: any[]) => any; export declare type EffectHook = ((...args: [Callback, Deps, ...RestArgs]) => void) | ((...args: [Callback, Deps]) => void); /** * Like `useEffect` but uses provided comparator function to validate dependency changes. * * @param callback Function that will be passed to underlying effect hook. * @param deps Dependencies list, like for `useEffect` hook. * @param comparator Function that compares two dependencies arrays, and returns true in case * they're equal. * @param effectHook Effect hook that will be used to run callback. Must comply `useEffect` * signature, meaning that callback should be placed as first argument and dependencies list * as second. * @param effectHookRestArgs Extra arguments that passed to effectHook. */ export declare function useCustomCompareEffect(callback: Callback, deps: Deps, comparator?: DependenciesComparator, effectHook?: EffectHook, ...effectHookRestArgs: R): void;