Skip to main content

LinkPreview

Import​

import { LinkPreview } from '@resultadosdigitais/tangram-components'

Properties​

url πŸ“β€‹

Concerns
πŸ“ Required
Typestring

Description​

Sets the URL to be previewed.

title​

Typestring

Description​

Sets the predefined title.

description​

Typestring

Description​

Sets the predefined description.

imageSrc​

Typestring

Description​

Sets the predefined image source.

fetcher​

Typefunc
DefaultLinkPreview.fetcher
Paramurl string - The url property.
ReturnsPromise - When resolved, it will return the data object associated with the URL page, this may include the title, description, and imageSrc attributes.

Description​

Sets the custom fetcher function. Must be an asynchronous function.

target​

Type
Enum of:
  • '_self'
  • '_blank'
  • '_parent'
  • '_top'
  • '_unfencedTop'
Default'_blank'

Description​

Where to display the linked URL.

For more information: https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Elements/a#target.

rel​

Typestring
Default'noreferrer'

Description​

The relationship between a linked resource and the current document.

For more information: https://developer.mozilla.org/en-US/docs/Web/HTML/Reference/Attributes/rel.

Feedback​

To report a problem or suggest changes, use our improvements form or, if you prefer, open an issue on our Github repository.