Skip to main content

Module citations

Module citations 

Source
Expand description

Citation parsing for Pandoc’s citations extension.

Syntax:

  • Bracketed: [@doe99], [@doe99; @smith2000]
  • With locator: [see @doe99, pp. 33-35]
  • Suppress author: [-@doe99]
  • Author-in-text: @doe99 (bare, without brackets)

Constants§

BOOKDOWN_LABEL_PREFIXES

Functions§

has_bookdown_prefix
has_custom_crossref_prefix
Whether key’s prefix (the segment before the first -) appears in custom_prefixes. Unlike is_quarto_crossref_key, this matches only the configured extension prefixes, so callers can tell an extension-injected cross-reference (whose target panache can’t resolve) apart from a built-in one (whose target it can and should validate).
is_bookdown_label
is_crossref_key
Like is_quarto_crossref_key, but also accepts any key whose prefix appears in custom_prefixes. Used to recognize cross-reference prefixes injected by Quarto extensions (e.g. pseudocode’s @algo-) that aren’t built in. Matching is case-insensitive on the prefix, consistent with the built-in check.
is_quarto_crossref_key
Try to parse a Quarto cross-reference key (e.g., @fig-plot, @eq-energy).