fix: use number | undefined for debounce timer ref (TS strict compat)
This commit is contained in:
@@ -23,7 +23,7 @@ export function useHeadingTitleSync({
|
||||
onTitleSync,
|
||||
}: HeadingTitleSyncConfig) {
|
||||
const syncActiveRef = useRef(true)
|
||||
const debounceTimerRef = useRef<ReturnType<typeof setTimeout> | undefined>(undefined)
|
||||
const debounceTimerRef = useRef<number | undefined>(undefined)
|
||||
const activeTabPathRef = useRef(activeTabPath)
|
||||
// eslint-disable-next-line react-hooks/refs
|
||||
activeTabPathRef.current = activeTabPath
|
||||
|
||||
Reference in New Issue
Block a user