Interlinks filter

The interlinks filter allows you to provide crossreferences within and between documentation. It consists of three pieces:

  1. Install: adding the extension to your quarto project.
  2. Configure: specifying sphinx inventories for the filter to use in your _quarto.yml config.
  3. Run: Generating sphinx inventories for the filter to use.

Installing

Use the quarto add command to install the interlinks filter:

quarto add machow/quartodoc
Note

The code for the filter can be found in quartodoc’s _extension folder

What is a sphinx inventory file?

Sphinx inventory files provide information about where the documentation for functions live on a website.

Most sphinx sites name them object.inv:

  • numpy: https://numpy.org/doc/stable/objects.inv
  • python: https://docs.python.org/3/objects.inv

See the sphobjinv docs for thorough details on these files, and how they’re used in sphinx.

Note

objects-test.txt is an example file with one entry: qd2.Auto.

More information

Under the hood, quarto doc generates sphinx inventories for an API e using create_inventory, and then dumps it to JSON using convert_inventory.

For an overview of the sphinx inventory format, see the sphobjinv docs.

The rough idea is that this plugin will behave similar to jupyterbook linking, which supports both some intersphinx syntax, but also markdown syntax.