LinkClickable()function

LinkClickable({
	href,
	disabled = !href,
	target,
	download,
	title,
	children = "Go",
	className,
}: StylableClickableProps): ReactElement
ParamType
propsStylableClickableProps
Props for a clickable that also accepts a className for styling. required
    .classNamestring
Return
ReactElement

Render an <a href=""> element, resolving its href against the current page URL and marking it active when it matches.

  • The href is resolved against the current page URL and site root so site-absolute paths (/foo) honour the base subfolder.
  • Sets aria-current="page" when the link points at the current URL.

Examples

<LinkClickable href="/about" className="link">About</LinkClickable>