UNPKG

@a24z/dynamic-file-tree

Version:

React component for selective directory filtering and file tree visualization

19 lines 632 B
import { RefObject } from 'react'; /** * Custom hook to track and update container height dynamically. * Listens to window resize events and updates the height accordingly. * * @param initialHeight - Initial height in pixels (default: 600) * @returns Tuple of [containerRef, containerHeight] * * @example * const [containerRef, height] = useContainerHeight(); * * return ( * <div ref={containerRef}> * <Tree height={height} ... /> * </div> * ); */ export declare const useContainerHeight: (initialHeight?: number) => [RefObject<HTMLDivElement | null>, number]; //# sourceMappingURL=useContainerHeight.d.ts.map