mirror of
https://github.com/supabase/supabase.git
synced 2026-06-04 03:41:38 +08:00
fix: runtime error of null reading scrolIIntoView
This commit is contained in:
@@ -46,7 +46,7 @@ const ContentAccordionLink = React.memo(function ContentAccordionLink(props: any
|
||||
if (activeItem && activeItemRef.current) {
|
||||
// this is a hack, but seems a common one on Stackoverflow
|
||||
setTimeout(() => {
|
||||
activeItemRef.current.scrollIntoView({ behavior: 'smooth', block: 'nearest' })
|
||||
activeItemRef.current?.scrollIntoView({ behavior: 'smooth', block: 'nearest' })
|
||||
}, 0)
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user