docs/widgets/markdown.md
!!! tip "Added in version 0.11.0"
A widget to display a Markdown document.
!!! tip
See [MarkdownViewer](./markdown_viewer.md) for a widget that adds additional features such as a Table of Contents.
The following example displays Markdown from a string.
=== "Output"
```{.textual path="docs/examples/widgets/markdown.py"}
```
=== "markdown.py"
~~~python
--8<-- "docs/examples/widgets/markdown.py"
~~~
This widget has no reactive attributes.
This widget has no bindings.
The markdown widget provides the following component classes:
::: textual.widgets.Markdown.COMPONENT_CLASSES options: show_root_heading: false show_root_toc_entry: false
::: textual.widgets.Markdown options: heading_level: 2