Extension figure

Include figures and images.

Figures are included by referring to their file. The source attribute refers to the image file, relative to the page. Usually it is a good idea to collect all images of a page or group of page in one folder, like shown below. Files are copied during the build process.

  • site/
    • pages/
      • index.md
      • hello.md
      • unit-1/
        • figures/
          • image.png
        • index.md
        • preparation.md

Formats can be jpg, png, pdf.

Captions are recommended.

Python typeFigure
typefigure
LanguageYAML
Required fieldssource
Optional fieldscaption, link
Post-Yaml Sectionno

Example 1

The TCP protocol uses state machines to describe parts of its behavior.

Source Code

---
type: figure
source: _placeholder 800 x 200
caption: "The TCP protocol uses state machines to describe parts of its behavior."
---
---
type: figure
source: _placeholder 800 x 200
caption: "The TCP protocol uses state machines to describe parts of its behavior."
---
Edit this page