Bluesky app fork with some witchin' additions 馃挮
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

at cope-settings-sync 14 lines 431 B view raw
1import {useEffect, useState} from 'react' 2 3export function useDelayedLoading(delay: number, isActuallyLoading: boolean) { 4 const [isDelayActive, setIsDelayActive] = useState(isActuallyLoading) 5 6 useEffect(() => { 7 if (!isDelayActive) return 8 9 const timeout = setTimeout(() => setIsDelayActive(false), delay) 10 return () => clearTimeout(timeout) 11 }, [isDelayActive, delay]) 12 13 return isDelayActive || isActuallyLoading 14}