vtils

Home > react > useReachBottom

useReachBottom() function

立即触发一次回调,并且每当到达页面底部时触发回调。

Signature:

export declare function useReachBottom<T extends HTMLElement>(callback: () => any, offset?: number): MutableRefObject<T>;

Parameters

Parameter Type Description
callback () => any 回调
offset number (Optional) 触底偏移量

Returns:

MutableRefObject<T>

返回