HandleBack

Function: handleBack()

[object Object]

Defined in: app/components/UI/PageHeader/PageHeader.handlers.tsx:14

Orchestrates back-navigation logic based on provided overrides or fallback routes.

This utility follows a priority order:

  1. If a custom onBack function is provided, it executes that logic exclusively.
  2. Otherwise, if a backTo string is provided, it uses the router's navigate function to redirect.

Parameters

onBack

(() => void) | undefined

An optional custom callback to execute instead of navigation.

backTo?

[object Object]

An optional route path to navigate to if no custom callback is provided.

[object Object]

The react-router navigation function instance.

Returns

[object Object]

On this page