Skip to contents

This article shows what pkgdown::build_site() produces on its own, straight from Quarto’s .qmd markup, with no quartofix()/quartofix2() cleanup run afterward. Callouts degrade to plain blockquotes, tabsets get mangled, and code annotations lose the JS that makes them interactive. Compare with the same article patched with quartofix() or patched with quartofix2() instead.

Callouts

Note

Callouts like this one keep their default title (“Note”) and are recovered exactly - type, icon, and color included.

This one has a custom title

pkgdown’s render loses the callout type along with a custom title like this one - quartofix() recovers it anyway by reading the .qmd source that produced this page and matching callouts positionally.

Warning

quartofix() only rewrites the first paragraph’s default title. A callout title spanning multiple lines is not currently supported.

Caution

Running quartofix() more than once is safe - already-patched files are detected and skipped.

Important

quartofix() must run after pkgdown::build_site(), not before - it patches the rendered HTML, not the .qmd source.

Tabsets

That doesn’t run the code:

Rscript -e 'pkgdown::build_site(); quartofix::quartofix()'

That runs the (R) code:

Rscript -e 'pkgdown::build_site(); quartofix::quartofix()'

Code annotations

1pkgdown::build_site()
2quartofix::quartofix()
1
Builds the site as usual - Quarto articles render with callouts, tabsets, and annotations all degraded.
2
Walks docs/, restores callout markup, and links in the small quartofix.css/quartofix.js bundle wherever it’s needed.

A normal blockquote

Here is an ordinary blockquote, to show it’s still intact:

Premature optimization is the root of all evil.

— Donald Knuth