Components
Components add structured content inside a layout. Use them when ordinary Markdown is not enough.
Choose by content
| Content | Components |
|---|---|
| Claims and formal statements | Theorem, Block, Highlight |
| Sources and papers | Citations, PaperCard |
| Results and evidence | MetricCard, MetricGrid, EvidenceBlock, ResultTable |
| Methods and data | EquationBlock, DatasetCard, Steps |
| Contributions and limits | ContributionList, CaveatList |
| Page composition | Columns, Keywords, ThemePreview |
Use a component
Components can wrap Markdown content:
markdown
<Theorem type="theorem" title="Pythagorean theorem">
For a right triangle, $a^2 + b^2 = c^2$.
</Theorem>Or accept data through props:
markdown
<MetricCard label="Accuracy" value="94.7" unit="%" />Open a component page for its props and complete examples. For shorter authoring syntax, see syntax sugar.
Blank lines around Markdown inside component tags allow Slidev to parse it correctly. Labels such as Paper and Evidence default to English; use each component's label or other text props when you need another language. The research names and numbers in examples are illustrative.