/**
* The target window or frame to open the linked document in.
*/
target?: string
/**
* Whether to navigate to the index page of the linked document.
*/
toIndex?: boolean
}
/**
* A higher-order component that injects the router object into its child component.
*
* @internal
* @deprecated - Use the `useRouter` hook instead.
*
* @returns The rendered component.
*
* @example
* ```tsx
* function MyComponent(props: {router: Router}) {
* const {location} = props.router
* const {pathname} = location
* return The current path is: {pathname}
* }
*
* function App() {
* return (
*
*
* {router => }
*
*
* )
* }
* ```
*/
export declare const WithRouter: FunctionComponent>
/**
* A higher-order component that injects the `router` object from the `useRouter` hook
* into the props of the wrapped component.
*
* @internal
* @deprecated - Use the `useRouter` hook instead.
*
* @param Component - The component to wrap.
*
* @returns The wrapped component.
*
* @example
* ```tsx
* function MyComponent(props) {
* return {props.router.state.myParam}
* }
*
* export default withRouter(MyComponent)
* ```
*/
export declare function withRouter<
Props extends {
router: RouterContextValue
},
>(Component: ComponentType): FunctionComponent>
/**
* @internal
* @deprecated - Use the `useRouter` hook instead.
*/
export declare interface WithRouterProps {
/**
* The `router` object from the `useRouter` hook.
* {@link RouterContextValue}
*/
router: RouterContextValue
/**
* A function that renders the wrapped component with the `router` object as a parameter.
*/
children: (router: RouterContextValue) => ReactElement
}
export {}