Customizable link previews

You control how TalkJS displays link previews for URLs shared in the chat. For example, you can choose to remove previews for links that contain certain blocked words. And you can now also set whether you prefer your link previews to show up large or compact.

By default, TalkJS generates a full, large preview for any link that a user shares. However, you can also set your link previews to be more compact.

A large link preview (on the left) and a compact link preview (on the right)


If you’d like your link previews to be more compact, then you can do so by setting the compact parameter of the LinkPreview or LinkPreviews components to true, as follows:

<LinkPreviews links="{{ body.links }}" t:if="{{ isSystemMessage | is_falsy }}" compact="{{ true }}" />

Read more on link previews.