import { StringMap } from '@react-force/utils'; import React from 'react'; import { RouterState } from '../stores'; export interface RouterLinkProps extends React.AnchorHTMLAttributes { routeName: string; params?: StringMap; queryParams?: { [key: string]: any; }; className?: string; activeClassName?: string; isActive?: (currentState: RouterState, toState: RouterState) => boolean; } /** * Creates an anchor tag that links to a router state. Redirects to the target * state without reloading the entire app, thus avoiding potential flickers. * * Example: * * Home * * * The target state is specified by the `routeName`, `params` and `queryParams` * properties. * * `RouterLink` accepts `className` and `activeClassName` as optional * properties to control the look of the link in normal and active states. * This feature is useful for highlighting the active link in a navbar. * The default test for checking if a link is active is very simple - the * routeName of the current RouterState should match the target routeName * of the link. For more control over this test, you can supply your own * custom `isActive` function. * * You can pass other anchor tag attributes (such as onClick and onBlur) to * this component. They will be passed through to the child anchor tag except * for `href`, which is fully computed by this component. */ export declare const RouterLink: React.FC;