about summary refs log tree commit diff
path: root/src/components/Lists.tsx
diff options
context:
space:
mode:
authorHailey <me@haileyok.com>2024-03-12 09:46:25 -0700
committerGitHub <noreply@github.com>2024-03-12 09:46:25 -0700
commitee57d74765e644de49c02de1e817eee0c6ed81aa (patch)
tree06945ebe5e8f856981cbfb25c81bdfcee807e43b /src/components/Lists.tsx
parentb8afb935f4eafbe64e83512ec5a97bb7b38a6ecb (diff)
downloadvoidsky-ee57d74765e644de49c02de1e817eee0c6ed81aa.tar.zst
Dedupe navigation events (push, navigate, pop, etc) (#3179)
Diffstat (limited to 'src/components/Lists.tsx')
-rw-r--r--src/components/Lists.tsx5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/components/Lists.tsx b/src/components/Lists.tsx
index 58aa74b38..bb0d24797 100644
--- a/src/components/Lists.tsx
+++ b/src/components/Lists.tsx
@@ -8,9 +8,8 @@ import {cleanError} from 'lib/strings/errors'
 import {Button} from '#/components/Button'
 import {Text} from '#/components/Typography'
 import {StackActions} from '@react-navigation/native'
-import {useNavigation} from '@react-navigation/core'
-import {NavigationProp} from 'lib/routes/types'
 import {router} from '#/routes'
+import {useNavigationDeduped} from 'lib/hooks/useNavigationDeduped'
 
 export function ListFooter({
   isFetching,
@@ -142,7 +141,7 @@ export function ListMaybePlaceholder({
   notFoundType?: 'page' | 'results'
   onRetry?: () => Promise<unknown>
 }) {
-  const navigation = useNavigation<NavigationProp>()
+  const navigation = useNavigationDeduped()
   const t = useTheme()
   const {gtMobile, gtTablet} = useBreakpoints()