Skip to content
This repository has been archived by the owner on Aug 20, 2022. It is now read-only.

Latest commit

 

History

History
50 lines (32 loc) · 1.33 KB

README.md

File metadata and controls

50 lines (32 loc) · 1.33 KB

Quarto Twitter embedding extions

A Quarto extension to embed tweets into an html document using a shortcode.

Note: The project is archived and will no longer be updated. The Twitter embed functionality is available in my quarto-social-embeds project.

Installation

Install the extension with:

quarto install extension sellorm/quarto-twitter-embed

Usage

To embed a Tweet into your Quarto html document you can use the shortcode like this:

{{< tweet <username> <id> >}}

or

{{< tweet user=<username> id=<id> >}}

This second option is provided for compatibility with Hugo.

For example:

{{< tweet sellorm 1555267341327503367 >}}

or

{{< tweet user=sellorm id=1555267341327503367 >}}

You can obtain the username and status id of a tweet by clicking the "share tweet" button and choosing "copy URL".

This will give you a URL like this one: https://twitter.com/sellorm/status/1555267341327503367?s=21&t=M0M4IA_KW-zMY1rb2XOWZQ. The "user" is the section between twitter.com/ and /status. The status "id" is everything between status/ and ? or the end of the URL, whichever comes first.

See example.qmd for a full example.