Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 6 additions & 7 deletions examples/next-app-router/components/NavigationProgress.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@ export function useNavigationProgress() {
return context
}

// Watches pathname/searchParams changes to detect when
// navigation has completed. Wrapped in Suspense because
// useSearchParams() requires a Suspense boundary.
// Watches pathname/searchParams changes to detect when navigation has
// completed. Wrapped in Suspense because useSearchParams() requires a Suspense
// boundary.
function NavigationComplete({ onComplete }: { onComplete: () => void }) {
const pathname = usePathname()
const searchParams = useSearchParams()
Expand All @@ -49,10 +49,9 @@ function NavigationComplete({ onComplete }: { onComplete: () => void }) {
return null
}

// Provides navigation progress state to the component
// tree. Navigation start is signalled via the onNavigate
// prop on a <ProgressLink>, and completion is detected by
// watching usePathname()/useSearchParams().
// Provides navigation progress state to the component tree. Navigation start is
// signalled via the onNavigate prop on a <ProgressLink>, and completion is
// detected by watching usePathname()/useSearchParams().
export default function NavigationProgress({
children,
}: {
Expand Down