Directives
Directives extend Markdown with additional features:
:::{note}
This is a callout box that stands out from regular text.
:::
How directive syntax works:
:::
opens and closes the directive block{note}
is the directive type (always in curly braces)- Content inside is regular Markdown
:::{image} screenshot.png
:alt: Dashboard overview
:width: 600px
:::
- Options start with
:
and appear after the opening line.
:::{include} shared-content.md
:::
The argument comes right after the directive name.
To nest directives, add more colons to the outer directive:
::::{note}
Outer content
:::{hint}
Inner content
:::
More outer content
::::
Use four colons (::::
) for the outer directive and three (:::
) for the inner one. Need to nest deeper? Keep adding colons.
Code blocks and applies_to
blocks use backticks instead of colons to prevent content from being processed as Markdown:
```js
const x = 1;
```
The following directives are available:
- Admonitions - Callouts and warnings
- Code blocks - Syntax-highlighted code
- CSV include - Render CSV files as tables
- Diagrams - Visual diagrams and charts
- Dropdowns - Collapsible content
- Images - Enhanced image handling
- Include - Include content from other files
- Settings - Configuration blocks
- Stepper - Step-by-step content
- Tabs - Tabbed content organization
- Tables - Data tables
- Version blocks - API version information