@linzjs/step-ag-grid
Version:
[](https://github.com/semantic-release/semantic-release) > Reusable [ag-grid](https://www.ag-grid.com/) component for LINZ / Toitū te whenua.
18 lines (17 loc) • 789 B
TypeScript
/**
* Copied from usehooks-ts
*
* Custom hook that creates an interval that invokes a callback function at a specified delay using the [`setInterval API`](https://developer.mozilla.org/en-US/docs/Web/API/WindowOrWorkerGlobalScope/setInterval).
* @param {() => void} callback - The function to be invoked at each interval.
* @param {number | null} delay - The time, in milliseconds, between each invocation of the callback. Use `null` to clear the interval.
* @public
* @see [Documentation](https://usehooks-ts.com/react-hook/use-interval)
* @example
* ```tsx
* const handleInterval = () => {
* // Code to be executed at each interval
* };
* useInterval(handleInterval, 1000);
* ```
*/
export declare function useInterval(callback: () => void, delay: number | null): void;