A hook that can lazy load resources such as image/video/audio/iframe/backgroundImage.
Basic usage of useLazyload hook.
Property | Description | Type | Default |
---|---|---|---|
callbackRef | The callback function for Ref | (el: HTMLElement | null) => void | - |
isLoaded | Whether the resource is loaded | boolean | false |