Hyperlink
minimal usage
with blank target
blank target without Icon
with onClick
with icon
color variants
link variants
destination
stringRequiredspecifies the URL
children
nodeRequiredContent of the hyperlink
className
stringCustom class names for the hyperlink
target
stringDefault'_self'specifies where the link should open. The default behavior is
_self, which means that the URL will be loaded into the same browsing context as the current one. If the target is_blank(opening a new window)rel='noopener'will be added to the anchor tag to prevent any potential reverse tabnabbing attack.onClick
funcDefault() => {}specifies the callback function when the link is clicked
externalLinkAlternativeText
isRequiredIf( PropTypes.string, props => props.target === '_blank', )Default'in a new tab'specifies the text for links with a
_blanktarget (which loads the URL in a new browsing context).externalLinkTitle
isRequiredIf( PropTypes.string, props => props.target === '_blank', )Default'Opens in a new tab'specifies the title for links with a
_blanktarget (which loads the URL in a new browsing context).variant
enum'default' | 'muted' | 'brand'Default'default'type of hyperlink
isInline
boolDefaultfalsespecify the link style. By default it will be underlined.
showLaunchIcon
boolDefaulttruespecify if we need to show launch Icon. By default it will be visible.